If you’re working on an Arcade type of game, you will need a Score System, so in this tutorial we will create one from scratch and add it to the template, this can be considered Part II of the Mobile Tutorial, but it’s also its own thing.
First create a new Blueprint Actor and call it “Enemy_Spawner” or something along those lines, add only a box component to it, to use as a volume for where the enemies will spawn.
After that create a new function for every type of enemy that should be spawned.
After that, create a Custom Event and recreate this Blueprint.
Now let’s move on to the GameMode, create a new Int variable (Score) and add this to Begin Play. What this will do is call the Custom Event from the Enemy_Spawner and spawn a random enemy every 2 seconds.
GAME OVER WIDGET
When the player health reaches 0, instead of the default respawn logic, simply create that new game over widget and add it to the viewport
If you followed all steps from this tutorial and the mobile tutorial, this should be the result, minus the assets of course..
As you can see the enemies attack you in random patterns, score gets added everytime you kill an enemy, on game over, it shows the total score.
You can expand this system to include other things as well.
NOTE: You can also download a slightly different (newer) version here. Wave Based Game Mode example, extract like it is in the zip file, open the level that comes with it, press play.