public HubScene(Happiness game) : base(game) { InputController.IC.OnClick += IC_OnClick; InputController.IC.OnDragBegin += IC_OnDragBegin; InputController.IC.OnDrag += IC_OnDrag; NetworkManager nm = NetworkManager.Net; // Setup Towers int centerX = Game.ScreenWidth >> 1; int centerY = Game.ScreenHeight >> 1; int towerSize = (int)(Constants.HubScene_TowerSize * Game.ScreenHeight); int towerTop = (int)(Constants.HubScene_TowerAreaTop * Game.ScreenHeight); int leftX = centerX - towerSize - towerSize; int midX = centerX - (towerSize >> 1); int rightX = centerX + towerSize; m_Towers = new Tower[6]; m_Towers[0] = new Tower(3, nm.GameData.TowerFloors[0], new Rectangle(leftX, towerTop, towerSize, towerSize), Assets.Towers[0]); m_Towers[1] = new Tower(4, nm.GameData.TowerFloors[1], new Rectangle(midX, towerTop, towerSize, towerSize), Assets.Towers[1]); m_Towers[2] = new Tower(5, nm.GameData.TowerFloors[2], new Rectangle(rightX, towerTop, towerSize, towerSize), Assets.Towers[2]); m_Towers[3] = new Tower(6, nm.GameData.TowerFloors[3], new Rectangle(leftX, centerY, towerSize, towerSize), Assets.Towers[3]); m_Towers[4] = new Tower(7, nm.GameData.TowerFloors[4], new Rectangle(midX, centerY, towerSize, towerSize), Assets.Towers[0]); m_Towers[5] = new Tower(8, nm.GameData.TowerFloors[5], new Rectangle(rightX, centerY, towerSize, towerSize), Assets.Towers[0]); // Level/Exp display int expBarWidth = (int)(Constants.HubScene_ExpBarWidth * Game.ScreenWidth); int expBarHeight = (int)(Constants.HubScene_ExpBarHeight * Game.ScreenHeight); int expBarLeft = (int)(Constants.HubScene_MarginLeftRight * Game.ScreenWidth); int levelY = (int)(Constants.HubScene_MarginTopBottom * Game.ScreenHeight); GameDataArgs gd = NetworkManager.Net.GameData; game.Tutorial.Load(gd.Tutorial); m_LevelLabel = new UILabel("Level: ", expBarLeft, levelY, Color.Goldenrod, Assets.HelpFont, UILabel.XMode.Left); m_Level = new UILabel(gd.Level.ToString(), expBarLeft + m_LevelLabel.Width, levelY, Color.White, Assets.HelpFont, UILabel.XMode.Left); m_ExpBar = new UIProgressBar(new Rectangle(expBarLeft, levelY + m_Level.Height, expBarWidth, expBarHeight)); m_ExpBar.ProgressColor = Color.Yellow; m_ExpBar.Progress = (float)gd.Exp / Balance.ExpForNextLevel(gd.Level); int tutorialWidth = (int)(Constants.HubScene_TutorialWidth * Game.ScreenWidth); Game.Tutorial.SetPieceData(TutorialSystem.TutorialPiece.ClickTower, new Vector2(leftX, towerTop + (towerSize >> 1)), 0, new Rectangle(leftX - (tutorialWidth + 5), towerTop + (towerSize >> 1) + (Game.Tutorial.ArrowHeight >> 1), tutorialWidth, 0), "Tap the 3x3 tower to get started.", TutorialSystem.TutorialPiece.None, m_Towers[0].Rect); Game.Tutorial.TriggerPiece(TutorialSystem.TutorialPiece.ClickTower); }
public HubScene(Happiness game) : base(game) { InputController.IC.OnClick += IC_OnClick; InputController.IC.OnDragBegin += IC_OnDragBegin; InputController.IC.OnDrag += IC_OnDrag; InputController.IC.OnScroll += IC_OnScroll; InputController.IC.OnKeyDown += IC_OnKeyDown; SoundManager.Inst.PlayMainMenuMusic(); //m_SoundDialog = new SoundDialog(game.ScreenWidth, game.ScreenHeight, game); //game.SoundManager.StopMusic(); // Setup Towers int centerX = Game.ScreenWidth >> 1; int centerY = Game.ScreenHeight >> 1; int towerSize = (int)(Constants.HubScene_TowerSize * Game.ScreenHeight); int towerTop = (int)(Constants.HubScene_TowerAreaTop * Game.ScreenHeight); int leftX = centerX - towerSize - towerSize; int midX = centerX - (towerSize >> 1); int rightX = centerX + towerSize; m_Towers = new Tower[6]; m_Towers[0] = new Tower(3, game.TheGameInfo.GameData.TowerFloors[0], new Rectangle(leftX, towerTop, towerSize, towerSize), Assets.Towers[0]); m_Towers[1] = new Tower(4, game.TheGameInfo.GameData.TowerFloors[1], new Rectangle(midX, towerTop, towerSize, towerSize), Assets.Towers[1]); m_Towers[2] = new Tower(5, game.TheGameInfo.GameData.TowerFloors[2], new Rectangle(rightX, towerTop, towerSize, towerSize), Assets.Towers[2]); m_Towers[3] = new Tower(6, game.TheGameInfo.GameData.TowerFloors[3], new Rectangle(leftX, centerY, towerSize, towerSize), Assets.Towers[3]); m_Towers[4] = new Tower(7, game.TheGameInfo.GameData.TowerFloors[4], new Rectangle(midX, centerY, towerSize, towerSize), Assets.Towers[0]); m_Towers[5] = new Tower(8, game.TheGameInfo.GameData.TowerFloors[5], new Rectangle(rightX, centerY, towerSize, towerSize), Assets.Towers[0]); // Level/Exp display int expBarWidth = (int)(Constants.HubScene_ExpBarWidth * Game.ScreenWidth); int expBarHeight = (int)(Constants.HubScene_ExpBarHeight * Game.ScreenHeight); int marginLeftRight = (int)(Constants.HubScene_MarginLeftRight * Game.ScreenWidth); int levelY = (int)(Constants.HubScene_MarginTopBottom * Game.ScreenHeight); m_LevelLabel = new UILabel("Level: ", marginLeftRight, levelY, Color.Goldenrod, Assets.HelpFont, UILabel.XMode.Left); m_Level = new UILabel(game.TheGameInfo.GameData.Level.ToString(), marginLeftRight + m_LevelLabel.Width, levelY, Color.White, Assets.HelpFont, UILabel.XMode.Left); m_ExpBar = new UIProgressBar(new Rectangle(marginLeftRight, levelY + m_Level.Height, expBarWidth, expBarHeight)); m_ExpBar.ProgressColor = Color.Yellow; m_ExpBar.Progress = (float)game.TheGameInfo.GameData.Exp / Balance.ExpForNextLevel(game.TheGameInfo.GameData.Level); SetupTutorial(); int buttonWidth = (int)(Constants.HubScene_ButtonWidth * Game.ScreenWidth); int buttonHeight = (int)(Constants.HubScene_ButtonHeight * Game.ScreenHeight); int buttonY = Game.ScreenHeight - levelY - buttonHeight; m_ResetTutorial = new UIButton(0, "Reset Tutorial", Assets.HelpFont, new Rectangle(marginLeftRight, buttonY, buttonWidth, buttonHeight), Assets.ScrollBar); m_Options = new UIButton(0, "Options", Assets.HelpFont, new Rectangle((marginLeftRight * 2) + buttonWidth, buttonY, buttonWidth, buttonHeight), Assets.ScrollBar); m_BuyCoins = new UIButton(0, "Buy Coins", Assets.HelpFont, new Rectangle((marginLeftRight * 3) + (buttonWidth * 2), buttonY, buttonWidth, buttonHeight), Assets.ScrollBar); int buttonRight = Game.ScreenWidth - marginLeftRight - buttonWidth; m_Exit = new UIButton(0, "Exit", Assets.HelpFont, new Rectangle(buttonRight, buttonY, buttonWidth, buttonHeight), Assets.ScrollBar); m_SignOut = new UIButton(0, "Sign Out", Assets.HelpFont, new Rectangle(buttonRight - marginLeftRight - buttonWidth, buttonY, buttonWidth, buttonHeight), Assets.ScrollBar); int startY = (int)(Constants.HelpPanel_Height * Game.ScreenHeight); int coinsWidth = (int)(Constants.HubScene_CoinsWidth * Game.ScreenWidth); int coinsLeft = Game.ScreenWidth - (coinsWidth + marginLeftRight); m_Coins = new UICoinsDisplay(startY, coinsLeft, levelY, coinsWidth); m_Coins.SetCoins(Game.TheGameInfo.HardCurrency); Game.OnCurrencyChange += Game_OnCurrencyChange; Game.OnVipDataChange += Game_OnVipDataChange; int vipTop = (levelY * 2) + m_Coins.Height; m_VIP = new UIVIPDisplay(coinsLeft + marginLeftRight, vipTop, coinsWidth - marginLeftRight); game.ValidateVIPSettings(); }
public VIPDialog() { Happiness game = Happiness.Game; int screenWidth = game.ScreenWidth; int screenHeight = game.ScreenHeight; int width = (int)(Constants.VIPDialog_Width * screenWidth); int height = (int)(Constants.VIPDialog_Height * screenHeight); int centerDialogX = (screenWidth >> 1); int left = centerDialogX - (width >> 1); int centerY = (screenHeight >> 1); int top = centerY - (height >> 1); m_Rect = new Rectangle(left, top, width, height); // Level/Exp display int expBarWidth = (int)(Constants.VIPDialog_ExpBarWidth * game.ScreenWidth); int expBarHeight = (int)(Constants.VIPDialog_ExpBarHeight * game.ScreenHeight); int marginTopBottom = (int)(Constants.VIPDialog_MarginTopBottom * game.ScreenWidth); int expBarLeft = centerDialogX - (expBarWidth >> 1); m_LevelLabel = new UILabel("Level: ", expBarLeft, marginTopBottom, Color.Goldenrod, Assets.DialogFont, UILabel.XMode.Left); m_Level = new UILabel(game.TheGameInfo.VipData.Level.ToString(), expBarLeft + m_LevelLabel.Width, top + marginTopBottom, Color.White, Assets.MenuFont, UILabel.XMode.Left); int xpBarTop = top + marginTopBottom + m_Level.Height; m_LevelLabel.PositionY = (xpBarTop - m_LevelLabel.Height) - 6; m_ExpBar = new UIProgressBar(new Rectangle(expBarLeft, xpBarTop, expBarWidth, expBarHeight)); m_ExpBar.ProgressColor = Color.DarkBlue; m_ExpBar.Progress = (game.TheGameInfo.VipData.Level >= 10) ? 1.0f : (float)game.TheGameInfo.VipData.Points / (float)VIPLevels.Levels[game.TheGameInfo.VipData.Level]; string expStr = (game.TheGameInfo.VipData.Level >= 10) ? game.TheGameInfo.VipData.Points.ToString("n0") : string.Format("{0} / {1}", game.TheGameInfo.VipData.Points.ToString("n0"), VIPLevels.Levels[game.TheGameInfo.VipData.Level].ToString("n0")); m_ExpText = new UILabel(expStr, centerDialogX, xpBarTop + expBarHeight, Color.WhiteSmoke, Assets.HelpFont, UILabel.XMode.Center); int buttonWidth = (int)(Constants.BuyCreditsDialog_ButtonWidth * screenWidth); int buttonHeight = (int)(Constants.BuyCreditsDialog_ButtonHeight * screenHeight); int centerButtonLeft = centerDialogX - (buttonWidth >> 1); int closeTop = (top + height) - (buttonHeight + marginTopBottom); m_Close = new UIButton(0, "Close", Assets.DialogFont, new Rectangle(centerButtonLeft, closeTop, buttonWidth, buttonHeight), Assets.ScrollBar); int levelsAreaTop = xpBarTop + expBarHeight + m_ExpText.Height + marginTopBottom; int levelsAreaWidth = (int)(Constants.VIPDialog_LevelsAreaWidth * screenWidth); int levelsAreaHeight = (closeTop - marginTopBottom) - levelsAreaTop; m_LevelsAreaFrame = new UIFrame(5, new Rectangle(centerDialogX - (levelsAreaWidth >> 1), levelsAreaTop, levelsAreaWidth, levelsAreaHeight)); int lrButtonSpace = (int)(Constants.VIPDialog_LRButtonSpace * screenWidth); int lrButtonWidth = (int)(Constants.VIPDialog_LRButtonWidth * screenWidth); int lrButtonHeight = (int)(Constants.VIPDialog_LRButtonHeight * screenHeight); int lrButtonTop = (levelsAreaTop + (levelsAreaHeight >> 1)) - (lrButtonHeight >> 1); m_BtnLeft = new UIButton(0, "<", Assets.MenuFont, new Rectangle(m_LevelsAreaFrame.Rect.Left - (lrButtonWidth + lrButtonSpace), lrButtonTop, lrButtonWidth, lrButtonHeight), Assets.ScrollBar); m_BtnRight = new UIButton(1, ">", Assets.MenuFont, new Rectangle(m_LevelsAreaFrame.Rect.Right + lrButtonSpace, lrButtonTop, lrButtonWidth, lrButtonHeight), Assets.ScrollBar); int lineSpace = (int)(Constants.VIPDialog_LineSpace * screenHeight); int rowY = levelsAreaTop + (lineSpace * 2); m_DetailsLevelLabel = new UILabel("VIP Level: 0", m_LevelsAreaFrame.Rect.Left + lrButtonSpace, rowY, Color.White, Assets.HelpFont, UILabel.XMode.Left); m_DetailsRequiredPoints = new UILabel("Points Required: 50000", m_LevelsAreaFrame.Rect.Right - lrButtonSpace, rowY, Color.White, Assets.HelpFont, UILabel.XMode.Right); rowY += m_DetailsLevelLabel.Height + (lineSpace * 3); m_HintsLabel = new UILabel("Hints (per puzzle): ", centerDialogX, rowY, Color.Goldenrod, Assets.DialogFont, UILabel.XMode.Right); m_Hints = new UILabel("0", centerDialogX, rowY, Color.Yellow, Assets.DialogFont, UILabel.XMode.Left); rowY += m_HintsLabel.Height + lineSpace; m_MegaHintsLabel = new UILabel("Mega Hints (per puzzle): ", centerDialogX, rowY, Color.Goldenrod, Assets.DialogFont, UILabel.XMode.Right); m_MegaHints = new UILabel("0", centerDialogX, rowY, Color.Yellow, Assets.DialogFont, UILabel.XMode.Left); rowY += m_HintsLabel.Height + lineSpace; m_UndoSizeLabel = new UILabel("Undo Size: ", centerDialogX, rowY, Color.Goldenrod, Assets.DialogFont, UILabel.XMode.Right); m_UndoSize = new UILabel("0", centerDialogX, rowY, Color.Yellow, Assets.DialogFont, UILabel.XMode.Left); rowY += m_HintsLabel.Height + lineSpace; m_ExpBonusLabel = new UILabel("Experience Bonus: ", centerDialogX, rowY, Color.Goldenrod, Assets.DialogFont, UILabel.XMode.Right); m_ExpBonus = new UILabel("1.5", centerDialogX, rowY, Color.Yellow, Assets.DialogFont, UILabel.XMode.Left); rowY += m_HintsLabel.Height + lineSpace; m_DisableTimer = new UILabel("Can Disable Timer", centerDialogX, rowY, Color.Yellow, Assets.DialogFont, UILabel.XMode.Center); rowY += m_HintsLabel.Height + lineSpace; m_DisableExpBonus = new UILabel("Can Disable VIP Exp Bonus", centerDialogX, rowY, Color.Yellow, Assets.DialogFont, UILabel.XMode.Center); rowY += m_HintsLabel.Height + lineSpace; m_ErrorDetector = new UILabel("Can enable the Error Detector", centerDialogX, rowY, Color.Yellow, Assets.DialogFont, UILabel.XMode.Center); rowY += m_HintsLabel.Height + lineSpace; m_ErrorDetector2 = new UILabel("Can enable the Super Error Detector", centerDialogX, rowY, Color.Yellow, Assets.DialogFont, UILabel.XMode.Center); SetDetailLevel(game.TheGameInfo.VipData.Level); }
public EndPuzzleScreen(bool success, int puzzleSize, double seconds, int screenWidth, int screenHeight, Happiness game) { m_bLevelUnlocked = false; m_bSuccess = success; m_Game = game; m_bLevelUpPlayed = false; m_iCenterX = screenWidth >> 1; int width = (int)(Constants.EndScreen_Width * screenWidth); int height = (int)(Constants.EndScreen_Height * screenHeight); int margin = (int)(Constants.EndScreen_MarginTopBottom * screenHeight); // rectangle m_Rect = new Rectangle(m_iCenterX - (width >> 1), (screenHeight >> 1) - (height >> 1), width, height); // Title int iTitleY = m_Rect.Top + margin; m_Title = new UILabel("Puzzle Complete!", m_iCenterX, iTitleY, Color.Goldenrod, Assets.DialogFont, UILabel.XMode.Center); // Success int iSuccessY = iTitleY + (int)(Constants.EndScreen_SuccessGap * screenHeight); m_Success = new UILabel(success ? "SUCCESS!" : "INCORRECT", m_iCenterX, iSuccessY, success ? Color.Green : Color.Red, Assets.MenuFont, UILabel.XMode.Center); // Buttons int buttonWidth = (int)(Constants.EndScreen_ButtonWidth * screenWidth); int buttonHeight = (int)(Constants.EndScreen_ButtonHeight * screenHeight); int buttonSpace = (int)(Constants.EndScreen_ButtonSpace * screenWidth); int buttonY = m_Rect.Bottom - (margin + buttonHeight); int halfButtonWidth = (buttonWidth >> 1); m_Buttons = new UIButton[3]; m_Buttons[0] = new UIButton(0, "Next Puzzle", Assets.HelpFont, new Rectangle(m_iCenterX + halfButtonWidth + buttonSpace, buttonY, buttonWidth, buttonHeight), Assets.ScrollBar); m_Buttons[1] = new UIButton(1, "Main Menu", Assets.HelpFont, new Rectangle(m_iCenterX - halfButtonWidth, buttonY, buttonWidth, buttonHeight), Assets.ScrollBar); m_Buttons[2] = new UIButton(2, "Restart Puzzle", Assets.HelpFont, new Rectangle(m_iCenterX - (halfButtonWidth + buttonSpace + buttonWidth), buttonY, buttonWidth, buttonHeight), Assets.ScrollBar); m_Buttons[0].Enabled = false; m_Buttons[1].Enabled = false; m_Buttons[2].Enabled = false; // Your time m_iTower = puzzleSize - 3; double parSeconds = Balance.ParTime(m_iTower); int quarterWidth = (width >> 2); int leftTimeX = m_iCenterX - quarterWidth; int rightTimeX = m_iCenterX + quarterWidth; int timeGap = (int)(Constants.EndScreen_TimeGap * screenHeight); int timeLabelY = iSuccessY + (int)(Constants.EndScreen_TimeLabelGap * screenHeight); m_TimeLabel = new UILabel("Your Time", leftTimeX, timeLabelY, Color.Goldenrod, Assets.DialogFont, UILabel.XMode.Center); m_Time = new UILabel(Happiness.TimeString(seconds), leftTimeX, timeLabelY + timeGap, (success && ((int)seconds <= parSeconds)) ? Color.Green : Color.Red, Assets.HelpFont, UILabel.XMode.Center); m_ParLabel = new UILabel("Par Time", rightTimeX, timeLabelY, Color.Goldenrod, Assets.DialogFont, UILabel.XMode.Center); m_Par = new UILabel(Happiness.TimeString(parSeconds), rightTimeX, timeLabelY + timeGap, Color.LightGray, Assets.HelpFont, UILabel.XMode.Center); m_Time.Hidden = true; // Scores float vipBonus = m_Game.ExpSlowdown ? 1.0f : m_Game.TheGameInfo.VipData.ExpBonus; double baseExp = success ? Balance.BaseExp(m_iTower) : 0; double bonusExp = success ? Balance.BonusExp(m_iTower, seconds) : 0; double totalExp = (baseExp + bonusExp) * vipBonus; m_iTotalExp = (int)totalExp; m_iExpStep = (int)((float)m_iTotalExp * 0.05f); int scoreCenterGap = (int)(Constants.EndScreen_ScoreCenterGap * screenWidth); int scoreSpace = (int)(Constants.EndScreen_ScoreSpace * screenHeight); int scoreBarWidth = (int)(Constants.EndScreen_ScoreBarWidth * screenWidth); int scoreBarHeight = (int)(Constants.EndScreen_ScoreBarHeight * screenHeight); int scoreL = m_iCenterX - scoreCenterGap; int scoreR = m_iCenterX + (scoreCenterGap * 3); int iScoreY = timeLabelY + timeGap + (int)(Constants.EndScreen_TimeScoreGap * screenHeight); m_ExpBaseLabel = new UILabel("Completion Exp:", scoreL, iScoreY, Color.Goldenrod, Assets.HelpFont, UILabel.XMode.Right); m_ExpBase = new UILabel(((int)baseExp).ToString(), scoreR, iScoreY, (baseExp > 0) ? Color.Green : Color.Gray, Assets.HelpFont, UILabel.XMode.Right); iScoreY += scoreSpace; m_ExpBonusLabel = new UILabel("Bonus Exp:", scoreL, iScoreY, Color.Goldenrod, Assets.HelpFont, UILabel.XMode.Right); m_ExpBonus = new UILabel(((int)bonusExp).ToString(), scoreR, iScoreY, (bonusExp > 0) ? Color.Green : Color.Gray, Assets.HelpFont, UILabel.XMode.Right); m_ScoreTotalBar = new Rectangle(m_iCenterX, iScoreY + scoreSpace, scoreBarWidth, scoreBarHeight); iScoreY += scoreSpace + scoreBarHeight + scoreBarHeight; m_ExpTotalLabel = new UILabel("Total Exp:", scoreL, iScoreY, Color.Goldenrod, Assets.HelpFont, UILabel.XMode.Right); m_ExpTotal = new UILabel(((int)totalExp).ToString(), scoreR, iScoreY, (totalExp > 0) ? Color.Green : Color.Gray, Assets.HelpFont, UILabel.XMode.Right); m_VipBonusExp = new UILabel(string.Format("x{0} VIP Bonus", vipBonus), scoreR + scoreSpace, iScoreY, Color.LightGreen, Assets.HelpFont, UILabel.XMode.Left); m_ExpBase.Hidden = true; m_ExpBonus.Hidden = true; m_ExpTotal.Hidden = true; m_VipBonusExp.Hidden = true; // Level up int expBarWidth = (int)(Constants.EndScreen_ExpBarWidth * screenWidth); int expBarHeight = (int)(Constants.EndScreen_ExpBarHeight * screenHeight); int expBarLeft = m_iCenterX - (expBarWidth >> 1); int levelY = iScoreY + scoreSpace + (int)(Constants.EndScreen_ScoreLevelGap * screenHeight); m_LevelLabel = new UILabel("Level: ", expBarLeft, levelY, Color.Goldenrod, Assets.HelpFont, UILabel.XMode.Left); m_Level = new UILabel(game.TheGameInfo.GameData.Level.ToString(), expBarLeft + m_LevelLabel.Width, levelY, Color.White, Assets.HelpFont, UILabel.XMode.Left); m_ExpBar = new UIProgressBar(new Rectangle(expBarLeft, levelY + m_Level.Height, expBarWidth, expBarHeight)); m_ExpBar.ProgressColor = Color.Yellow; m_iOriginalLevel = m_Game.TheGameInfo.GameData.Level; m_iOriginalExp = m_Game.TheGameInfo.GameData.Exp; SetupExpDisplay(); // Unlock int iUnlockY = m_ExpBar.Rect.Bottom + (int)(Constants.EndScreen_LevelUnlockGap * screenHeight); m_Unlock = new UILabel(string.Format("Tower {0} Unlocked!", m_iTower + 2), m_iCenterX, iUnlockY, Color.Yellow, Assets.MenuFont, UILabel.XMode.Center); m_Unlock.Hidden = true; int waitIconSize = (int)(Constants.EndScreen_WaitIconSize * game.ScreenWidth); m_WaitRect = new Rectangle((game.ScreenWidth / 2) - (waitIconSize / 2), (game.ScreenHeight / 2) - (waitIconSize / 2), waitIconSize, waitIconSize); m_AnimStep = success ? AnimStep.WaitForServerData : AnimStep.Start; m_AnimTimeRemaining = 1.0f; if (!game.Tutorial.IsPieceSetup(TutorialSystem.TutorialPiece.EndScreen1)) { int instRW = (screenWidth - 20) - (m_ScoreTotalBar.Right + 30); Rectangle instRect = new Rectangle(m_ScoreTotalBar.Right + 30, m_ExpBonus.PositionY + game.Tutorial.ArrowHeight, instRW, 0); game.Tutorial.SetPieceData(TutorialSystem.TutorialPiece.EndScreen1, new Vector2(m_ScoreTotalBar.Right + 10, m_ExpBonus.PositionY), Constants.ArrowLeft, instRect, "When you complete a puzzle you gain a set amount of experience points based on the puzzle difficulty.\n\nYou also get a bonus amount of experience points that varies depending on the amount of time it took you to finish the puzzle.", TutorialSystem.TutorialPiece.EndScreen2, Rectangle.Empty, true); game.Tutorial.SetPieceData(TutorialSystem.TutorialPiece.EndScreen2, new Vector2(m_iCenterX, m_ExpBar.Rect.Top - 5), Constants.ArrowDown, instRect, "As you gain experience, you will increase in levels.\n\nAs you increase in levels, you will unlock the larger towers for harder puzzles.", TutorialSystem.TutorialPiece.EndScreen3, Rectangle.Empty, true); instRect.Y -= 10; game.Tutorial.SetPieceData(TutorialSystem.TutorialPiece.EndScreen3, new Vector2(m_Buttons[0].Rect.Center.X, m_Buttons[0].Rect.Top - 5), Constants.ArrowDown, instRect, "Tap the Next Puzzle button to move on to the second puzzle.", TutorialSystem.TutorialPiece.Puzzle2, m_Buttons[0].Rect); game.Tutorial.SetPieceData(TutorialSystem.TutorialPiece.EndScreen4, new Vector2(m_Buttons[0].Rect.Center.X, m_Buttons[0].Rect.Top - 5), Constants.ArrowDown, instRect, "Tap the Next Puzzle button to move on to the next puzzle.", TutorialSystem.TutorialPiece.Horizontal_NextTo, m_Buttons[0].Rect); game.Tutorial.SetPieceData(TutorialSystem.TutorialPiece.EndScreen4b, new Vector2(m_Buttons[1].Rect.Center.X, m_Buttons[1].Rect.Top - 5), Constants.ArrowDown, instRect, "Pay closer attention to the tutorial text. If you dont read it, you won't understand how to solve the puzzles.", TutorialSystem.TutorialPiece.None, m_Buttons[1].Rect); } game.Tutorial.FinishPiece(TutorialSystem.TutorialPiece.Puzzle2, TutorialSystem.TutorialPiece.EndScreen4b, success); }