My problem is either incredibly simple or complex.
I have discovered a weird input lag that applies to touch controls.
In my game, the player can either press the Q key if on PC, or tap a button if on mobile, and if the player's stamina is 100, this action sets off a "punch" variable which temporarily sets the player's animation and movement to be punching.
The problem is, on specifically mobile, the player is able to spam the button, and the game waits to set their stamina to 0. This problem does not exist with keyboard controls. It is pretty game-breaking, so any help is appreciated.
Heres a video of someone doing the glitch:
Heres my code: