This script allows you to define “Parameter bonuses” for your actors and enemies. A paramter bonus is simply a bonus that will be added to your parameters based on a formula. The bonus itself could be an increase, or even a decrease in stats if you provide a negative value.
For example, suppose you had custom parameters that allowed you to define stats like “strength” or “intelligence”, where str increases your atk and max HP params while int increases magic attack and magic defense stats. You can use parameter bonuses to define formulas that will allow your str and int stats to contribute to the other parameters.
Since the parameter bonus can be any formula, you can define bonuses based on anything.
Parameter bonuses can be defined in actors, classes, weapons, armors, states, and enemies. Actors will inherit any bonuses defined in their class, equips, and states. Enemies will inherit any bonuses defined in their states.
Because equips and states can be changed, you can use this to create unique effects.
Script: download here
In the script editor, place this script below Materials and above Main
To define a parameter bonus, note-tag actors or enemies with
<param bonus: TYPE> FORMULA </param bonus>
Where the TYPE is one of
mhp - max HP mmp - max MP atk - attack def - defense mat - magic attack mdf - magic defense agi - agility luk - luck
And the formula can be any valid ruby formula.
The following formula variables are available
a - the actor p - game party t - game troop v - game variables s - game switches
You can define multiple parameter bonuses for an actor, and you can define
multiple bonuses for the same stat; simply add more of the note-tag.
Do not have a bonus stat referencing the same stat. For example, if your atk
bonus relies on your atk stat, your game will crash. Similarly, if your
atk stat relies on your str stat, which relies on your atk stat, your game
will also crash. If your game crashes because your formula is wrong, it is
likely not a bug in the script.
Suppose we have a custom stat called “str”. For each point in str, you gain 10 HP. For every 5 points in str, you gain 1 atk. You would use two parameter bonuses:
<param bonus: mhp> a.str * 10 </param bonus> <param bonus: atk> a.str / 5 </param bonus>