Wait doesn't prevent your second event from going off every tick.
So in that 2 seconds you are waiting, that second event will keep running, and keep queuing up the action to set state to shooting. After 2 seconds is up, for the next two seconds it will keep setting SpecificState to "Shooting"
Your third event only runs once, right when the first 2 seconds is up. It shoots and sets the state to hiding. But the previous action was queued up for 2 seconds more and keeps setting the state back to Shooting. Since your third event has trigger once, you never get to set SpecificState back to hiding.