- Joined
- Nov 16, 2016
- Messages
- 325
- Reaction score
- 75
- First Language
- English
Hi everyone.
I'm trying to create a state, that at the end of an actor or enemy's turn whom is affected by the state, will force a skill on them.
For instance, in a Custom Turn End Effect, I would like to force skill 54.
Using the "BattleManager.queueForceAction" command does not work, as skill 54 will endlessly repeat on the user. Here is how the actual skill is set up:
Initially I was using "Custom Action End Effect" and thought if I swapped it to Turn End, it would stop the infinite loop because skill 54 was considered an action. However, it made no difference.
So I thought I could try this instead:
Whereby if the flag was not on, it would execute the skill, followed by immediately turning the flag on so it would not execute the skill a second time. However, instead of endlessly repeating the skill in this case, it does not even occur once.
So now I'm a bit stuck, and was wondering how to execute a skill in a custom effect that only occurs on the user once.
Keep in mind, the poison idea is just a generic test, so I'm not really after advice on how to create a general poison skill in other more efficient ways.
Thanks!!!
I'm trying to create a state, that at the end of an actor or enemy's turn whom is affected by the state, will force a skill on them.
For instance, in a Custom Turn End Effect, I would like to force skill 54.
Using the "BattleManager.queueForceAction" command does not work, as skill 54 will endlessly repeat on the user. Here is how the actual skill is set up:
Initially I was using "Custom Action End Effect" and thought if I swapped it to Turn End, it would stop the infinite loop because skill 54 was considered an action. However, it made no difference.
So I thought I could try this instead:
JavaScript:
<Custom Turn End Effect>
if (! a._isThisForceActionInitiated) {
a.forceAction(54);
a._isThisForceActionInitiated = true;
}
</Custom Turn End Effect>
<Custom Turn Start Effect>
a._isThisForceActionInitiated = false;
</Custom Turn Start Effect>
So now I'm a bit stuck, and was wondering how to execute a skill in a custom effect that only occurs on the user once.
Keep in mind, the poison idea is just a generic test, so I'm not really after advice on how to create a general poison skill in other more efficient ways.
Thanks!!!

