I'm trying to make a pretty unorthodox enemy attack.
This attack does damage to a single target that ignores defense. (formula for this part being a.atk * 4)
However in addition to dealing damage, I also want it to add a state to a specific party member 5% of the time, if this attack targeted that specific party member. Only a specific party member though, and her actor id is 4. It does that damage to everyone else including her, it's just if it targeted her, it has a 5% chance of giving her a state. I know this part of the formula would involve something with "if b.id == 4" and "b.add_state(25)", 25 being the id of the specific state I want it to add, but I don't know what I'm supposed to do with those things, especially because I want it to give her this state only 5% of the time. How would I do this?
This attack does damage to a single target that ignores defense. (formula for this part being a.atk * 4)
However in addition to dealing damage, I also want it to add a state to a specific party member 5% of the time, if this attack targeted that specific party member. Only a specific party member though, and her actor id is 4. It does that damage to everyone else including her, it's just if it targeted her, it has a 5% chance of giving her a state. I know this part of the formula would involve something with "if b.id == 4" and "b.add_state(25)", 25 being the id of the specific state I want it to add, but I don't know what I'm supposed to do with those things, especially because I want it to give her this state only 5% of the time. How would I do this?