Have a switch that releases keyboard command on release, not allowing action again until it is flipped, to stop things like holing down space to infinitely jump, and possibly for melee attack. Shoot should have holding though, just use it for things that shouldn't.
See if doing this lets you remove the timer code, I think it should.
Have a switch that releases keyboard command on release, not allowing action again until it is flipped, to stop things like holing down space to infinitely jump, and possibly for melee attack. Shoot should have holding though, just use it for things that shouldn't.
See if doing this lets you remove the timer code, I think it should.