public void Warp(PowerupStateType t) { if (!underground) { underground = true; LoadLevel(GameUtility.UndergroundFile); } else if (underground) { underground = false; LoadLevel(GameUtility.ReturnToLevelOneFile); } Player.StateMachine.State = t; }
public void GoToShop(PowerupStateType t) { if (!shop) { shop = true; lastLocation = Player.Location; LoadLevel(GameUtility.ShopFile); } else { shop = false; LoadLevel(GameUtility.InitialLevelFile); Player.Location = lastLocation; } Player.StateMachine.State = t; }
public ICommand CreateWarpCommand(PowerupStateType t) { return(new WarpCommand(myGame, t)); }
public WarpCommand(Game1 g, PowerupStateType t) { this.myGame = g; myType = t; }