Thank you so much! There's still only one problem I can think of in order to prevent it from being 'buggy' How can I be sure that the player never released the fire button?
For example, a buggy thing that I could forsee being a possible problem is, if a player presses the fire button to shoot a pipe, releases the fire button and goes to press the fire button again as the previous pipe touches another player or a surface. It seems I need a method like what you've provided but I also need to be able to check if the player ever released the fire button.
IN_ATTACK means button is pressed will fire each time it is pressed... how ever if you do it like ongameframe(in css) it will check constantly so if you release it it stops.