Hi so I'm trying to make a pokemon style game with turn-based combat. Line 11 checks to see if an instance variable "EnemyTurn" is true, and if so then line 12 will apply damage to the Player ONCE while "EnemyTurn" is true, and line 13 will set "EnemyTurn" to false if the Player's HP is greater than 0.
The PROBLEM is that, occasionally, the damage will be applied around 4-6 times in a second even though it should only be applied once. Somehow the "EnemyTurn" variable is being set to true multiple times in a second? Please help not sure what I'm doing wrong.