/** * The default scene constructor. */ public ArenaScene() : base() { instance = this; loaded = false; // Create the arena controller controller = new ArenaController(); // Define the user actions menu = InputAction.Y; pause = InputAction.START; rotateDown = new InputAction( new Buttons[] { Buttons.RightThumbstickDown }, new Keys[] { Keys.K }, false ); rotateUp = new InputAction( new Buttons[] { Buttons.RightThumbstickUp }, new Keys[] { Keys.I }, false ); bgm = SoundUtils.Music.ArenaTheme; pauseMenu = new MenuPanel("Pause Menu", new List<MenuItem>() { new MenuItem("Resume Game", pause), new MenuItem("Main Menu", menu) }); }
public void menuNewGame() { ArenaScene arena = new ArenaScene(); PartyUtils.Reset(); SceneManager.setScene(SceneState.arena, arena, true); }
public ArenaScene(SaveData data) : base() { instance = this; loaded = true; // Create the arena controller controller = new ArenaController(data); // Set the player hp List<PlayerSprite> party = PartyUtils.getParty(); party[0].setHealth(data.partyHealth[0]); party[1].setHealth(data.partyHealth[1]); party[2].setHealth(data.partyHealth[2]); // Define the user actions menu = InputAction.Y; pause = InputAction.START; rotateDown = new InputAction( new Buttons[] { Buttons.RightThumbstickDown }, new Keys[] { Keys.NumPad2 }, false ); rotateUp = new InputAction( new Buttons[] { Buttons.RightThumbstickUp }, new Keys[] { Keys.NumPad8 }, false ); bgm = SoundUtils.Music.ArenaTheme; pauseMenu = new MenuPanel("Pause Menu", new List<MenuItem>() { new MenuItem("Resume Game", pause), new MenuItem("Main Menu", menu) }); }
public void menuLoadGame() { SaveData data = SaveUtils.getInstance().loadGame(); ArenaScene arena = new ArenaScene(data); SceneManager.setScene(SceneState.arena, arena, true); }