예제 #1
0
 public void Reset()
 {
     if (CanReset && State is WorldState)
     {
         State        = new WorldState(this);
         CanReset     = false;
         Time         = Utils.Instance.InitialTimeLeft;
         Player       = new Player();
         PrimaryWorld = WorldFactory.CreatePrimaryWorld(worldID);
         PrimaryWorldCollisionDetection = new CollisionDetection(PrimaryWorld);
         HiddenWorld = WorldFactory.CreateHiddenWorld(worldID);
         HiddenWorldCollisionDetection = new CollisionDetection(HiddenWorld);
         if (InPrimaryWorld)
         {
             Player.MovementState.Location = PrimaryWorld.PlayerSpawn;
         }
         else
         {
             Player.MovementState.Location = HiddenWorld.PlayerSpawn;
         }
         remainingResetTime = Utils.Instance.PauseTime;
         SongManager.Instance.PlayOverworldMusic();
     }
 }
예제 #2
0
 public void CreateHiddenWorld()
 {
     HiddenWorld = WorldFactory.CreateHiddenWorld(worldID);
     HiddenWorldCollisionDetection = new CollisionDetection(HiddenWorld);
 }