public override void Update(GameTime gameTime) { if (Game1.spriteManager.boss.bState == Boss.BossState.Phase2 && !initiatedPhase2and3) { enemySpawner = new EnemySpawner(20, 45, true, false, false, false); initiatedPhase2and3 = true; } if (Game1.spriteManager.boss.bState == Boss.BossState.Finished) { Game1.spriteManager.clearScene(false); Game1.particleManager.Update(gameTime); enemySpawner = new EnemySpawner(false, false, false, false); pickupSpawner = new PickupSpawner(false, false, false); Game1.spriteManager.boss.Kill(true); if (ticksRemaining <= 0) { gameStateManager.setLevel(12); } if (ticksRemaining > 0) { ticksRemaining--; } } // Handle our player input PlayerInput.Update(); Levels.handleLevelHotKeys(gameStateManager); // Update our Sprite Manager Game1.spriteManager.Update(); // Update our Particle Manager Game1.particleManager.Update(gameTime); // Update our Enemy Spawner enemySpawner.Update(Game1.spriteManager.count); // Update our Pickup Spawner pickupSpawner.Update(Game1.spriteManager.count); }
public static void handleLevelUpdate(GameTime gameTime, RC_GameStateManager gameStateManager, EnemySpawner enemySpawner, PickupSpawner pickupSpawner, PlayerGUI playerGUI, int scoreReq, int nxtLvl) { // Check our win conditions if (Resources.score > scoreReq) { gameStateManager.setLevel(nxtLvl); } Levels.handleLevelHotKeys(gameStateManager); // Update our Sprite Manager Game1.spriteManager.Update(); // Update our Particle manager Game1.particleManager.Update(gameTime); // Update our Enemy Spawner enemySpawner.Update(Game1.spriteManager.count); // Update our Pickup Spawner pickupSpawner.Update(Game1.spriteManager.count); }