Time for action - adding a Player GameObject

  1. Add Player to Scene0. We also need to make changes to Scene1 and Scene2.
  2. Click on GameManager and make sure its Transform Position is 0,0,0.
  3. Add Player to Scene0.
  4. Set the Transform Position for Player to 0,1,0.
  5. Make Player a child object of the GameManager by dragging Player onto GameManager. Why?
    • Player needs to be able to exist in every Scene
    • Since GameManager is already allowed to exist in all Scenes as a result of the DontDestroyOnLoad() method called in StateManager, any child objects of GameManager will also be allowed to exist in all Scenes
  6. I suggest adding Directional Light to Scene0 so everything added to the Scene isn't dark.
  7. Make it a child of GameManager as well so that all Scene instances will ...

Get Learning C# by Developing Games with Unity 3D Beginner's Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.