O'Reilly logo

Unreal Engine Game Development Blueprints by Nicola Valcasara

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Gameplay

It is time to complete this project, merging together what we did so far and adding the gameplay scripts.

The game mechanic of the game expected:

  • A timer that goes down each second
  • An energy that is used by the player when accelerating the ship and a ship that can accelerate only if it has enough energy
  • A score that increases each time an item is collected
  • A game over that is shown when the player ends its time
  • The possibility to restart the game as many times as the player desires
  • Collectables that spawn periodically

For GameOver, we can create a third UI window that shows the score and the button of the main menu; however, let's keep it simple. We can connect a second event called GameOver on an HUD class BeginPlay event. This will be called ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required