protected override void Initialize() { keyboard = new KeyboardController(); gamepad = new GamepadController(this); camera = new Camera(UtilityClass.cameraHeight, UtilityClass.cameraWidth, new Vector2(UtilityClass.zero, UtilityClass.zero)); pipeTransition = new PipeTransition(); skytransition = new SkyWorldTransition(); gameover = new GameOver(this); loader = new LevelLoader(UtilityClass.levelFile, camera); levelStore = new LevelStorage(camera); keyNotPressed = new KeyNotPressed(this); fireBallCount = UtilityClass.fireballLimit; iceBallCount = UtilityClass.iceballLimit; pause = false; canPause = true; marioPause = false; stateTransistionPauseTimer = UtilityClass.stateTransistionTimer; time = new TimeStat(UtilityClass.LevelStartTime); gui = new GUI(); StatePuaseAlterationCall.setGame(this); AchievementPause.setGame(this); achievementManager = new AchievementManager(); AchievementEventTracker.setManager(achievementManager); base.Initialize(); tester = new TestingClass(this, levelStore); tester.runTests(); AchievementEventTracker.endRunningTesting(); pole = new Pole(); flag = new Flag(); hitFlagpole = false; levelWon = false; vine_box_hit = false; VineClimbBeginLocation = new Vector2(30, 0); }
public EndingSequenceMario(Mario mario, bool smallMario, bool fireMario, bool iceMario, TimeStat time) { this.location = mario.Location; endActions = mario.actions; endStats = mario.stats; timeStats = time; timeStats.SaveTime(); this.smallMario = smallMario; endSequenceFinished = false; atFlagpoleBottom = false; flagAtBottom = false; offBlock = false; flagpoleAnimation = true; fallOffBlockAnimation = false; walkingToCastle = false; slideSpeed = UtilityClass.slideSpeed; walkSpeed = UtilityClass.endMarioWalkSpeed; decayRate = UtilityClass.endMarioDecayRate; waitToLeaveFlagpole = UtilityClass.waitToLeaveFlagpole; endMarioSprite = new EndingSequenceMarioSprite(location, smallMario, fireMario, iceMario); }