I need to keep count of how many enemy's spawned on the layout and once it meets the limit it will stop spawning them in order for the level to be complete.
Example: once an enemy is killed I am creating a new enemy at a random spot, but I want the spawning to stop once it reaches 25 enemy's.
Any idea how I can make this happen, I already have the condition that once 25 enemys are killed it ends the level but I want there to be no enemy's on screen when the end of the level is reached.
Any help would be appreciated!