public InventoryMenu(MainStage game) { this.game = game; Background = new GeneralSprite(length, width, frame); Selection = new GeneralSprite(square, square, frame); MapSprite = new GeneralSprite(square, square, frame); BombSprite = new GeneralSprite(square, square, frame); BowSprite = new GeneralSprite(square, square, frame); CompassSprite = new GeneralSprite(square, square, frame); BoomerSprite = new GeneralSprite(square, square, frame); }
public MouseController(MainStage instance) { quitGameCommand = new QuitGameCommand(instance); setSpriteCommands = new ICommand[(int)GlobalDefinitions.SpriteModes.Invalid]; setSpriteCommands[(int)GlobalDefinitions.SpriteModes.StaticFixed] = new SetSpriteCommand(instance, GlobalDefinitions.SpriteModes.StaticFixed); setSpriteCommands[(int)GlobalDefinitions.SpriteModes.StaticVerticalMoving] = new SetSpriteCommand(instance, GlobalDefinitions.SpriteModes.StaticVerticalMoving); setSpriteCommands[(int)GlobalDefinitions.SpriteModes.AnimatedFixed] = new SetSpriteCommand(instance, GlobalDefinitions.SpriteModes.AnimatedFixed); setSpriteCommands[(int)GlobalDefinitions.SpriteModes.AnimatedHorizontalMoving] = new SetSpriteCommand(instance, GlobalDefinitions.SpriteModes.AnimatedHorizontalMoving); }
public KeyboardController(MainStage instance) { controllerMappings = new Dictionary <Keys, ICommand>(); controllerMappings.Add(Keys.NumPad0, new QuitGameCommand(instance)); controllerMappings.Add(Keys.D0, new QuitGameCommand(instance)); controllerMappings.Add(Keys.NumPad1, new SetSpriteCommand(instance, GlobalDefinitions.SpriteModes.StaticFixed)); controllerMappings.Add(Keys.D1, new SetSpriteCommand(instance, GlobalDefinitions.SpriteModes.StaticFixed)); controllerMappings.Add(Keys.NumPad2, new SetSpriteCommand(instance, GlobalDefinitions.SpriteModes.AnimatedFixed)); controllerMappings.Add(Keys.D2, new SetSpriteCommand(instance, GlobalDefinitions.SpriteModes.AnimatedFixed)); controllerMappings.Add(Keys.NumPad3, new SetSpriteCommand(instance, GlobalDefinitions.SpriteModes.StaticVerticalMoving)); controllerMappings.Add(Keys.D3, new SetSpriteCommand(instance, GlobalDefinitions.SpriteModes.StaticVerticalMoving)); controllerMappings.Add(Keys.NumPad4, new SetSpriteCommand(instance, GlobalDefinitions.SpriteModes.AnimatedHorizontalMoving)); controllerMappings.Add(Keys.D4, new SetSpriteCommand(instance, GlobalDefinitions.SpriteModes.AnimatedHorizontalMoving)); }
public MenuGamepadController(MainStage instance) { this.instance = instance; controllerMappings = new Dictionary <Buttons, ICommand>(); controllerMappings.Add(Buttons.RightTrigger, new ResumeGameCommand(instance)); controllerMappings.Add(Buttons.Back, new QuitGameCommand(instance)); controllerMappings.Add(Buttons.LeftTrigger, new ResetGameCommand(instance)); controllerMappings.Add(Buttons.Start, new PauseGameCommand(instance)); controllerMappings.Add(Buttons.DPadUp, new SelectUpCommand(this.instance.InventoryMenu)); controllerMappings.Add(Buttons.DPadLeft, new SelectLeftCommand(this.instance.InventoryMenu)); controllerMappings.Add(Buttons.DPadDown, new SelectDownCommand(this.instance.InventoryMenu)); controllerMappings.Add(Buttons.DPadRight, new SelectRightCommand(this.instance.InventoryMenu)); }
public MenuKeyBroadController(MainStage instance) { this.instance = instance; controllerMappings = new Dictionary <Keys, ICommand>(); controllerMappings.Add(Keys.Space, new ResumeGameCommand(instance)); controllerMappings.Add(Keys.Q, new QuitGameCommand(instance)); controllerMappings.Add(Keys.R, new ResetGameCommand(instance)); controllerMappings.Add(Keys.P, new PauseGameCommand(instance)); controllerMappings.Add(Keys.W, new SelectUpCommand(this.instance.InventoryMenu)); controllerMappings.Add(Keys.Up, new SelectUpCommand(this.instance.InventoryMenu)); controllerMappings.Add(Keys.A, new SelectLeftCommand(this.instance.InventoryMenu)); controllerMappings.Add(Keys.Left, new SelectLeftCommand(this.instance.InventoryMenu)); controllerMappings.Add(Keys.S, new SelectDownCommand(this.instance.InventoryMenu)); controllerMappings.Add(Keys.Down, new SelectDownCommand(this.instance.InventoryMenu)); controllerMappings.Add(Keys.D, new SelectRightCommand(this.instance.InventoryMenu)); controllerMappings.Add(Keys.Right, new SelectRightCommand(this.instance.InventoryMenu)); }
public GamepadController(MainStage instance) { lastButtonPressed = Buttons.Back; this.instance = instance; gamepadMappings = new Dictionary <Buttons, ICommand>(); gamepadMappings.Add(Buttons.Back, new QuitGameCommand(instance)); gamepadMappings.Add(Buttons.Start, new PauseGameCommand(instance)); gamepadMappings.Add(Buttons.LeftTrigger, new ResetGameCommand(instance)); gamepadMappings.Add(Buttons.DPadUp, new UpMovingCommand(this.instance.Link)); gamepadMappings.Add(Buttons.DPadLeft, new LeftMovingCommand(this.instance.Link)); gamepadMappings.Add(Buttons.DPadDown, new DownMovingCommand(this.instance.Link)); gamepadMappings.Add(Buttons.DPadRight, new RightMovingCommand(this.instance.Link)); gamepadMappings.Add(Buttons.A, new StandingWoodenSwordCommand(this.instance.Link)); gamepadMappings.Add(Buttons.X, new UseArrowCommand(this.instance.Link)); gamepadMappings.Add(Buttons.B, new UseBombCommand(this.instance.Link)); gamepadMappings.Add(Buttons.Y, new UseBoomerCommand(this.instance.Link)); }
public ContinueGameCommand(MainStage game) { this.game = game; }
public SetSpriteCommand(MainStage instnace, SpriteModes mode) { GameInstnace = instnace; SpriteMode = mode; }
public ResumeGameCommand(MainStage game) { this.game = game; }
public PauseGameCommand(MainStage game) { this.game = game; }
public DungeonLevel(MainStage game) { this.game = game; }