So, I have two party characters I'm trying to develop some unique abilities for. I have an idea how the traits and such work but I'm not sure I can make these abilities happen.
One character's ability needs to activate when her HP drops below 25% which will increase her defense and magic defense but will decrease attack. The other character's ability activates at random which grants her x2 attack power to whatever move she uses but at the cost of decreasing her rate for that attack.
I'm wondering how I could set this up or will I need some sort of plugin(s) to get this to work? I guess what I'm asking is how do I set these up to trigger or activate at random?
This is relatively easy to do if you use Yanfy BuffState Core. For the first Ability, you can check at the beginning of the turn or after enemy attacks if the hp of your character is below 25%, if it is, activate the ability.
Same for the second ability, at the beginning of the turn (or at the end or both) do a random eval and if it checks, activate ability.
Both abilities can have their effect created by states, that is not the problem.
The difficult part is the trigger as to when the states are triggered.
This can be done either by plugins or by troop events. In case of troop events they should run every turn or every action, test for the values and then add or remove the states as required.
This can be done without plugins by simply copying the troop event into every troop, or you can add a base troop plugin that copies all that to every troop automatically.
that would be the plugin mentioned above, and you would have to know javascript to place the condition as a notetag for the plugin to read - it's helpfile should have that somewhere as a condition for an autostate or passive state.
or if you don't want to use a plugin you can place the trigger inside a troop event like i mentioned above.
Hi! No worries, hope those adjustments were positive =)
On my code I assumed that you apply the effects via another state, thats where " user.addState(X)" line come into effect, X is the number of the state you want to apply.
So to summarize, you need to apply a permanent state that contains my code. And you need to create another state where you put your effects (more strength, less speed, etc etc).
In the state that contains my code, change the X value for the number of the state that contains your effects. And it should work!
Mmm...I dont quite understand your question. If you want a specific character with the enabler state, you apply that state only to the character you want. in this case, your main character.
So you have Yanfly auto passive states?
Place: <Passive State: X> on the actor (main character) notetag.
where X is the Id of the enabler state.
This answers your question? Im a bit confused he he
Oh yes I do have this plugin but not turned on yet. I downloaded it the other day thinking it could solve my problem. I'll try it and get back with you.
Okay that worked but here is the problem now lol
The enemies are getting the states when I hit them lol