Making a QTE Event

So, I want to make a sequence in my event in which a player must pass a QTE to avoid damage. (For those not savvy on what a QTE is: you press a button to avoid damage/death/etc.) I have no idea how to do this in a script, but I believe it involves timers and conditional branches. I made the following in an attempt to replicate what I want to happen (sorry it's not a screenshot, cba to go through that entire process atm):

@>Control Timer: Startup (0 min. 5 sec.)@>Conditional Branch: Timer 0 min 0 sec or less @>Control Timer: Stop @>Jump to Label: Fail @>@>Branch End@>Conditional Branch: The A Button is Being Press @>Control Timer: Stop @>Jump to Label: Succeed @>@>Branch End@>Label: Fail@>Change HP: Entire Party - 50@>Label: Succeed@>(Player pushes enemy back, nothing important here)... but all it does is freeze my game. Since I have no clue what I'm doing and don't want to add even MORE scripts to my game (I'm already having issues with one of them), I'd love to know a possible workaround for this. It might involve switches and more event pages, but if possible, I'd love to completely avoid adding more as I already have 4 for this event and I don't want to add more (again, only if possible). Thank you!
you need to split the sections into different events.

A conditional branch for a button press needs to be in a parallel process to check, but if the timer command is in the same parallel process, it will reset the timer before it can work.

For further help, we really need to see the screenshots, because an event is more than the contents - as seen above, triggers and conditions are extremely important here and only a full screenshot will show the entire event.
This is the event page.

LjcO3M0.png


The first two are just for controlling the sprite and making it appear (which is what the self-switch is for), and the fourth one is exactly the same barring that it uses a switch for the slow-walking mechanic I have, which shouldn't have any affect on this sequence. I've included them below in case they might be of any use, but I doubt it.

Spoiler
9mghNcV.png
oEkNLQk.png


h3GQXF0.png
my first attempt would be to place the button and timer branch in a loop and exit the loop when the button is pressed with(or to) succeed and when the timer runes up with(to) fail. A quick test shows me also that there should be a wait of a couple frames so the game doesn't slow down
 

Original thread: https://forums.rpgmakerweb.com/threads/making-a-qte-event.54485/