public Sounds(Game game, GameMode gameMode) : base(game) { this.gameMode = gameMode; // TODO: Construct any child components here prevLens = gameMode.ActiveLens; }
public Goal(Game game, GameMode gm, Vector3 position, Vector3 widths) : base(game) { gameMode = gm; _boundingBox = new BoundingBox(position,position+widths); // TODO: Construct any child components here }
public Stalker(Game1 game, GameMode gm) : base(game) { // TODO: Construct any child components here Size = Vector3.One/4; Position = Vector3.Zero; _gameMode = gm; prevLens = gm.ActiveLens; }
public LevelComponent(Game1 game, GameMode gameMode, string wallsFile) : base((Game)game) { this.gameMode = gameMode; WallsFile = wallsFile; System.IO.Stream stream = TitleContainer.OpenStream(wallsFile); XDocument doc = XDocument.Load(stream); Walls = ReadWalls(doc); Coins = ReadCoins(doc); Traps = ReadTraps(doc); Goal = ReadGoal(doc); }
public Coin(Game game, GameMode gameMode) : base(game) { this.gameMode = gameMode; }
public Lens(Game game, GameMode gameMode) : base(game) { // TODO: Construct any child components here this.gameMode = gameMode; }
public RedLens(Game game, GameMode gameMode) : base(game, gameMode) { // TODO: Construct any child components here }
public void WinGame() { victoryScreen = new VictoryScreen(this, SpriteBatch); activeScreen = Screen.VictoryScreen; List<GameComponent> toRemove = new List<GameComponent>(); foreach (GameComponent component in Components) { if (component is Wall || component is Trap || component is Coin || component is Lens || component is Player || component is Sounds || component is HUD || component is Goal || component is Stalker) toRemove.Add(component); } foreach (GameComponent gameComponent in toRemove) { Components.Remove(gameComponent); } gameMode = null; }
public void startGameMode() { gameMode = new GameMode(this); activeScreen = Screen.GameMode; startScreen = null; gameOverScreen = null; }
public void GameOver() { gameOverScreen = new GameOverScreen(this, SpriteBatch, Sprite); activeScreen = Screen.GameOverScreen; gameMode = null; List<GameComponent>toRemove = new List<GameComponent>(); foreach (GameComponent component in Components) { if (component is Wall || component is Trap || component is Coin || component is Lens || component is Player || component is Sounds || component is HUD || component is Goal || component is Stalker)toRemove.Add(component); } foreach (GameComponent gameComponent in toRemove) { Components.Remove(gameComponent); } }
public Level01(Game1 game, GameMode gameMode) : base(game, gameMode, "Content\\level_01.xml") { }
public Trap(Game game, GameMode gameMode) : base(game) { this.gameMode = gameMode; // TODO: Construct any child components here }