Hi every one!
Let me see if I can explain this:
I'm trying to make an state that debuffs the target and also buff the caster. In this case, the buff will be "Atk". And the buff start as an amout and then decrease each turn until reachs to 0, when the state is removed.
For exemple:
Let's take an state that reamains for 3 turns, and with 15% debuff on the first turn, decreasing to 10% and 5% until the state is removed.
>When the state is applied and every turn start:
set turnCouter = turnCouter || 3;
var steal = Math.floor(target.atk * 0.5 * turnCouter);
target.atk -= steal;
origin.atk += steal;
>When the turn ends:
turnCounter -= 1;
reset.targetAtk;
reset.originAtk;
I'm watching all the Tips & Tricks playlist from Yanfly to help me, but i still don't have idea how to set the counter, and to buff and debuff exactly the same amout (x% from the TARGET atack. If the target has 100 and the origin has 200, the amount that would increase/decrease is 15 for both), and reset the buff/debuff as well.
If Kes is the one who'll moderate this, I hope I posted this thread in the right forum.
Thank you all!
Let me see if I can explain this:
I'm trying to make an state that debuffs the target and also buff the caster. In this case, the buff will be "Atk". And the buff start as an amout and then decrease each turn until reachs to 0, when the state is removed.
For exemple:
Let's take an state that reamains for 3 turns, and with 15% debuff on the first turn, decreasing to 10% and 5% until the state is removed.
>When the state is applied and every turn start:
set turnCouter = turnCouter || 3;
var steal = Math.floor(target.atk * 0.5 * turnCouter);
target.atk -= steal;
origin.atk += steal;
>When the turn ends:
turnCounter -= 1;
reset.targetAtk;
reset.originAtk;
I'm watching all the Tips & Tricks playlist from Yanfly to help me, but i still don't have idea how to set the counter, and to buff and debuff exactly the same amout (x% from the TARGET atack. If the target has 100 and the origin has 200, the amount that would increase/decrease is 15 for both), and reset the buff/debuff as well.
If Kes is the one who'll moderate this, I hope I posted this thread in the right forum.
Thank you all!