Hello!
So I have a battle that allows player to evade manually, using SRDude plugin called Active Defense Charge.
It's done by modifying the "Attack" skill notetag.
I want to automatically activate a counterattack whenever the player successfully evade.
To achieve that effect, I think that requires some kind of switch activation or conditional branch from notetag.
Is it possible to activate switch or conditional branch via notetag?
For more information, I also use Yanfly Action Sequence and Counter Control.
<Target Action>
enemy sequence attack go here
if (!target.result().isHit())
actor counter attack go here
end
</Target Action>
Thanks!
Anyway, here's the code I put in attack notetag:
<setup action>
display action
immortal: targets, true
</setup action>
<target action>
if user.attackMotion() !== 'missile'
move user: targets, front, 20
else
perform start
end
wait for movement
motion attack: user
wait: 10
attack animation: target
wait for animation
action effect
<Active Defense: charge>
<End Active Defense>
if (!target.result().isHit())
<Timed Attack: clock>
Target 1: 45, 180, rgba(200, 170, 0, 1), 1
Target 2: 200, 270, rgba(220, 150, 0, 1), 2
Target 3: 290, 330, rgba(240, 130, 0, 1), 3
<End Timed Attack>
</target action>
The timed attack is the counterattack.
But it activated straight away after I select attack command, not after I can evade enemy attack.
Do I have to add this code first?
if ($gameActors.actor(1).meta["notetag"] ==" dgutdf") {
//code}
Thanks!
I'm messing around and found a code that truly make it work.
But the no damage problem is still there.
<setup action>
display action
immortal: targets, true
</setup action>
<target action>
if user.attackMotion() !== 'missile'
move user: targets, front, 20
else
perform start
end
wait for movement
motion attack: user
wait: 10
attack animation: target
wait for animation
action effect: target
<Active Defense: charge>
<End Active Defense>
if $ActiveDefense.power <= 0
wait: 10
else
motion attack: target
wait: 10
attack animation: user
wait for animation
action effect: user
end
</target action>
The bolded part is the one that checks whether the player successfully dodge or not.
With that code, I successfully make the actor counter only when they dodged enemy attack.
But that's the problem, there's no damage on the counterattack.
Is there a way to call another skill instead if the actor successfully dodge? (like calling common event)
Something like this:
if $ActiveDefense.power <= 0
wait: 10
else
call counterattack skill
I want to do this as well, I'm trying to find a way.
I think it's just the damage formula to change :dizzy: