I might be trying to do something that maybe is immensely over complicating a non-issue, but I'm trying to jury rig Visu Core's base parameter formula to work a certain way.
I think it might be best if I show what I'm trying to do in a visual way.
Here's the normal parameter formula:
And here's what I'm trying to do:
Here's the full javascript that's used, for context purposes.
So what I'm trying to do is use the base (The value set in the database) as the flat starting number, and use the flatBonus as a set number added to the parameter every level. I'm just not sure how to get the actor level.
Could I just use another plugin? Yes, yes I could. I just want to see if my stupid idea is even doable.
I think it might be best if I show what I'm trying to do in a visual way.
Here's the normal parameter formula:
Code:
(base + plus) * paramRate * buffRate + flatBonus
And here's what I'm trying to do:
Code:
base + (flatBonus * current actor level) * paramRate * buffRate + plus
Here's the full javascript that's used, for context purposes.
JavaScript:
// Determine the variables used in this calculation.
let paramId = arguments[0];
let base = this.paramBase(paramId);
let plus = this.paramPlus(paramId);
let paramRate = this.paramRate(paramId);
let buffRate = this.paramBuffRate(paramId);
let flatBonus = this.paramFlatBonus(paramId);
// Formula to determine total parameter value.
let value = (base + plus) * paramRate * buffRate + flatBonus;
// Determine the limits
const maxValue = this.paramMax(paramId);
const minValue = this.paramMin(paramId);
// Final value
return Math.round(value.clamp(minValue, maxValue));
So what I'm trying to do is use the base (The value set in the database) as the flat starting number, and use the flatBonus as a set number added to the parameter every level. I'm just not sure how to get the actor level.
Could I just use another plugin? Yes, yes I could. I just want to see if my stupid idea is even doable.