So, for my game, I wanted to have certain skills that one-shot you when you have a certain status. For example, if an enemy is affected by a charm status, then a hero uses a heartstopper that instantly kills the foe. Are there any suggestions for getting this to work?
special instakill
RPG Maker MZ SupportI've done something like this by putting the following into the skill's damage formula:
replacing 13 with the index of the status.
if (b.isStateAffected(13)){ b.die(); }replacing 13 with the index of the status.
it would be safer to use a plugin like yanfly's skill core and moving the instakill logic there.
It would work for a player, but putting that as a part of the damage formula will make it so that any enemy or autobattle actor with access with that skill will kill any opponent with that state active just by "considering" using that move. they wouldnt need to execute the skill. that code would be ran on each target and kill all applicable ones automatically before the choice as to what skill to even use would be made
It would work for a player, but putting that as a part of the damage formula will make it so that any enemy or autobattle actor with access with that skill will kill any opponent with that state active just by "considering" using that move. they wouldnt need to execute the skill. that code would be ran on each target and kill all applicable ones automatically before the choice as to what skill to even use would be made
Good to know, to be fair I hadn't properly tested that formula 😅 I'm just really hesitant to much of anything with plugins if I think I can do it myself...
Sooo... do you know any plugins that can do that?
To be fair, the OP is using MZ.
So you could use my Eval Tags plugin or, if you're already using VisuStella, their Battle Core.
With my Eval Tags you'd put on the skill
Code:
<Action Apply Eval>
if (target.isStateAffected(42))
target.die();
</Action Apply Eval>
I downloaded the plugin and tried using it, but it didn't work. this is how I have it in.
Because your skill isn't doing anything, so it never enters the apply() function.
You could make it do any amount of damage, or you could enter Effects (such as Add State on a dummy state and then Remove State on the exact same thing).
You could make it do any amount of damage, or you could enter Effects (such as Add State on a dummy state and then Remove State on the exact same thing).
Original thread: https://forums.rpgmakerweb.com/threads/special-instakill.168494/