public void UpdateSubPanels() { // show sub-panels based on activity ActorGameManager.ShowGroup(playModeControlsPanelName, State.gameActivity == GameActivity.play); ActorGameManager.ShowGroup(editModePanelName, State.gameActivity == GameActivity.edit); ActorGameManager.ShowGroup(testModePanelName, State.gameActivity == GameActivity.test); }
public void ResetBoard() { Database.AddBoardMetric(metricType.play); ActorGameManager.ShowGroup(helpPanelName, false); ActorGameManager.ShowGroup(dialogPanel, false); ActorGameManager.ResetBoard(); }
public void EnterTestMode() { ActorGameManager.ShowGroup(testModePanelName, true); ActorGameManager.ShowGroup(playModeControlsPanelName, false); ActorGameManager.ShowGroup(editModePanelName, false); ActorGridManager.EnterTestMode(); ActorGameManager.EnterTestMode(); ActorGameManager.ShowGroup(helpPanelName, false); }
public void CancelHint() { ActorGameManager.ShowGroup(getHintPanel, false); // Send Analytics Event Analytics.CustomEvent("Funnel", new Dictionary <string, object> { { State.GetBoardDisplayName(), 1 }, { "HintCancelStore", 1 } }); }
public void UndoTurn() { // only charge gems when in normal play mode (not when in edit or test) if (Identity.GetGems() < 1 && State.gameActivity == GameActivity.play) { ActorGameManager.ShowGroup(getHintPanel, true); } else { ActorGameManager.UndoTurn(); } }
public void BuyGems() { ActorGameManager.ShowGroup(getHintPanel, false); StartCoroutine("LoadLevel", "store"); // Send Analytics Event Analytics.CustomEvent("Funnel", new Dictionary <string, object> { { State.GetBoardDisplayName(), 1 }, { "HintOpenStore", 1 } }); }
IEnumerator ShowPopularBoards() { yield return(null); State.gameBoardCategory = GameBoardCategory.popular; State.gameBoardMine = false; State.gameSource = GameSource.remote; State.gameActivity = GameActivity.play; ActorGameManager.ShowGroup(pageUpButton, true); ActorGameManager.ShowGroup(pageDownButton, true); Database.GetPopularBoards(true); }
IEnumerator ShowMyBoards() { yield return(null); State.gameBoardCategory = GameBoardCategory.mine; State.gameBoardMine = true; State.gameSource = GameSource.remote; State.gameActivity = GameActivity.play; ActorGameManager.ShowGroup(pageUpButton, false); ActorGameManager.ShowGroup(pageDownButton, false); Database.GetMyBoards(); }
public void GrantCredits(int credits) { Debug.Log(string.Format("ProcessPurchase: PASS. Gems: '{0}'", credits)); int currentGems = Identity.GetGems(); screen.SetGemCountDisplay(currentGems + credits); Identity.AddGems(credits); StoreResultText.text = "You successfully purchased " + credits.ToString() + " Gems!"; ActorGameManager.ShowGroup(StoreResultPanelName, true); }
IEnumerator ShowBeginnerBoards() { yield return(null); Debug.LogWarning("Showing Story Boards for BoardList"); State.gameBoardCategory = GameBoardCategory.campaign; State.gameBoardMine = false; State.gameSource = GameSource.local; State.gameActivity = GameActivity.play; ActorGameManager.ShowGroup(pageUpButton, false); ActorGameManager.ShowGroup(pageDownButton, false); Database.GetLocalBoards(); }
void Update() { if (State.gameState == GameState.boardList) { // the board list has been returned // so the board buttons can be built now // set the state back to boards to prevent re-building State.gameState = GameState.boards; Debug.LogWarning("Boardlist returned, building board buttons..."); ActorGameManager.ShowGroup(yardButtonsPanelTag, State.gameSource == GameSource.remote); StartCoroutine("BuildBoardButtons", State.gameBoardList); } }
public void GetHint() { if (Identity.GetGems() < 1) { ActorGameManager.ShowGroup(getHintPanel, true); // Send Analytics Event Analytics.CustomEvent("Funnel", new Dictionary <string, object> { { State.GetBoardDisplayName(), 1 }, { "HintOutOfGems", 1 } }); } else { ActorGameManager.ShowHint(); } }
private void Start() { audioManager = GameObject.FindGameObjectWithTag("AudioManager").GetComponentInChildren <ActorAudioManager>(); audioManager.playScreenLoaded(); // only show voting button when the board is not mine ActorGameManager.ShowGroup(voteForBoardButton, !State.gameBoardMine); // update sub-panels based on activity UpdateSubPanels(); // only show the social buttons when the player is age 15 or older ActorGameManager.ShowGroup(twitterButton, State.GetAgeFifteenOrOlder()); ActorGameManager.ShowGroup(facebookButton, State.GetAgeFifteenOrOlder()); Language.TranslateScreen(); // set board name GameObject.Find(boardNameText).GetComponent <Text>().text = State.GetBoardDisplayName(); // cache board number boardNumber = State.GetBoardNumber(); }
public void ShowHelp() { ActorGameManager.ShowGroup(helpPanelName, true); ScrollToTop(helpScrollView); }
public void PurchaseFailed() { StoreResultText.text = "Your purchase was not successful."; ActorGameManager.ShowGroup(StoreResultPanelName, true); }
public void GoNextBoard() { ActorGameManager.ShowGroup(nextBoardButton, false); ActorGameManager.GoNextBoard(); StartCoroutine("LoadLevel", "play"); }
public void HideHelp() { ActorGameManager.ShowGroup(helpPanelName, false); }
public void VoteForBoard() { ActorGameManager.ShowGroup(voteForBoardButton, false); Database.AddBoardMetric(metricType.vote); }
public void HideFoundTrinketPanel() { ActorGameManager.ShowGroup(ActorGameManager.foundTrinketPanel, false); }
public void CloseStoryView() { ActorGameManager.ShowGroup("StoryScrollView", false); }
public void StoryNow() { ActorGameManager.ShowGroup(storyUnlockPanel, false); StartCoroutine("LoadLevel", "chapters"); }
public void StoryLater() { ActorGameManager.ShowGroup(storyUnlockPanel, false); }
public void ResultPanelOk() { ActorGameManager.ShowGroup(StoreResultPanelName, false); }
public void ShowSaveBoard() { ActorGameManager.ShowGroup(saveBoardPanelName, true); ActorGameManager.ShowGroup(helpPanelName, false); }
public void ShowChapter(string chapterName) { ActorGameManager.ShowGroup("StoryScrollView", true); storyText.text = Database.GetChapterText(chapterName); StartCoroutine("ScrollToTop"); }