About 'Reset Game Session'!

cud_s05_reset_game_session

#1

In this video (objectives)…

  1. Reinforce the public method paradigm we've been using.
  2. Fix the issue with our score persisting from game session to game session.
  3. How to rename a class.

After watching (learning outcomes)… How to elegantly reset our game session so that our score resets.

(Unique Video Reference: 27_BR_CUD)

We would love to know…

  • What you found good about this lecture?
  • What we could do better?

Remember that you can reply to this topic, or create a new topic. The easiest way to create a new topic is to follow the link in Resources. That way the topic will…

  • Be in the correct forum (for the course).
  • Be in the right sub-forum (for the section)
  • Have the correct lecture tag.

Enjoy your stay in our thriving community!


#2

Hi, when I’m trying to call the ResetGame method from SceneLoader.cs, I’m getting the red squigglies. I’m not sure what I’ve done wrong.

When I tried the challenge initially, here is what I wrote. I just tried to make it similar to how it was structured in Level.cs. Regarding this, when is it appropriate to use ‘cached references’ and FindObjectOfType in the way we did in Level.cs?

(Note: I havent renamed GameStatus yet)


#3

Red squigglies might be because you’re missing parentheses after your method - ResetGame()


#4

Oh my god, I feel like an idiot.


#5

Its all part of being a programmer. :slight_smile: