Help in loading up a GUI when timer hits or when a target score is hit

Hi
I am not a developer and have looked at the manuals and YouTube videos and i am struggling to load a youLose GUI when the timer reaches 0 or load a youWin GUI when the score reaches a certain score.

I was hoping if someone could help me or show me how this is done? I have attached my game and if anyone could have a look I would be very appreciative.

Thanks

SpaceGame.zip (251.6 KB)

It looks like you’ve are on the right track, you just need to keep going. Since GUIs are components you will need to make a game object file with the GUI component on it, and then use a factory to spawn it at the appropriate time.

In your main gui script, I would also add an “if” with a condition to check which message you are receiving. Presumably you don’t want to add score when any message is received, only when an enemy is destroyed by the player.

3 Likes