Hey guys, I am having a little bit of difficulty creating a skill. I am essentially trying to make a skill similar to what the bombs in Final Fantasy has, where the enemy blows up, killing itself and damaging the players.
I have tried several ways, including adding a.add_state(1)to the damage formula. While this does seem to kill the enemy, it leaves it battle on the screen.
Any suggestions?
Just put:
a.hp -= a.hp; damage_formulaas the formula and it should kill the attacker as the skill is used.
How odd, similar to above, that works but the battler remains on the battlefield.
What scripts are you using, that shouldn't be happening. (what about killing them normally?)
Don't use a conditional branch in the battle event for the switch. You see the box that says 'Condition: Turn number 0'? change that condition to show that the switch is on instead, a conditional branch in the event would only be used for checking multiple enemies to see which one has the dummy state in a troop where you have more than one enemy with the 'burst' skill. The way you have it set up it will check for the switch being on only on turn 0 (which is before anyone can have any chance to choose an action) changing that to: switch[0002] is on will make the event activate whenever the switch is turned on, but if you have more than one with the skill again make sure you set span to 'turn' so that it can occur more than once. (also make sure at the end of that event you turn the switch off, otherwise after using the skill once all enemies with the burst skill will instantly die at the beginning of each battle.)
Edit: actually lower the enemies hp by it's max amount (or 999999 is what I tested) I'm not sure what is going on with actually applying the death state but it doesn't seem that it works like it should.
Yay. That worked. Thank you VERY much, Alexander!
I found a workaround for this. (since i am also working on a kamikaze enemy). Without having to use switches.
In your damage formula, you can put a.perform_collapse_effect to force the collapse effect.
So personally i have :
"a.hp -= 5;a.perform_collapse_effect;5"
which deals 5 damages to itself and the party.
(I'm letting future people know if they stumble upon this thread like I did).