Hello, so I'm trying to make a battle system that will let your character dodge if they hit a button when prompted to, but I'm having trouble getting it to work the way I want.
The problem I'm having is adding a timing function to the button prompt so that the player has a certain amount of time to hit the button and avoid the attack. I've tried all sorts of things and I just can't get this function to work.
Currently I'm using SRD Timer Upgrade, and Yanflys action sequences.
I have the event set up so that when the timer runs out it calls on a common event that will activate a switch which will activate the rest of the action sequence for the enemy battler.
So basically it goes timer starts, button prompt, player has 60 frames to hit a button, if player hits button he gets a buff to nullify damage, timer end activates a common event (plugin command SetExpireCommonEvent 2), common event activates a switch which should prompt the enemy battler to perform their attack.
The problem is that the enemy always attacks as soon as the timer starts. This is the action sequence:
<setup action>
common event: 1
common event: 3
if $gameSwitches.value(4, true)
move user: forward, 200, 60
wait for movement
change switch 4: off
change variable 4 = 0
end
</setup action>
This is just one of several attempts I've made trying to do this and they all have the same problem where I can't make a timer for the input. I know what I've got works to some degree because there is a brief moment where I can input the button and get the status effect to trigger, but the battle system always skips any timing event I try and implement.
Thanks
The problem I'm having is adding a timing function to the button prompt so that the player has a certain amount of time to hit the button and avoid the attack. I've tried all sorts of things and I just can't get this function to work.
Currently I'm using SRD Timer Upgrade, and Yanflys action sequences.
I have the event set up so that when the timer runs out it calls on a common event that will activate a switch which will activate the rest of the action sequence for the enemy battler.
So basically it goes timer starts, button prompt, player has 60 frames to hit a button, if player hits button he gets a buff to nullify damage, timer end activates a common event (plugin command SetExpireCommonEvent 2), common event activates a switch which should prompt the enemy battler to perform their attack.
The problem is that the enemy always attacks as soon as the timer starts. This is the action sequence:
<setup action>
common event: 1
common event: 3
if $gameSwitches.value(4, true)
move user: forward, 200, 60
wait for movement
change switch 4: off
change variable 4 = 0
end
</setup action>
This is just one of several attempts I've made trying to do this and they all have the same problem where I can't make a timer for the input. I know what I've got works to some degree because there is a brief moment where I can input the button and get the status effect to trigger, but the battle system always skips any timing event I try and implement.
Thanks