public void UpdateDisplayItemData() { LogUtil.Log("UIPanelModeTypeChoice:UpdateDisplayItemData"); UIColors.UpdateColors(); UIUtil.SetLabelValue(labelDisplayItemStatus, GetStatusItemProgress()); AppContentChoice choice = GetCurrentChoice(); if (choice != null) { string choiceTitle = "Loading..."; string choiceQuestion = "Loading..."; if (choice != null) { choiceTitle = "Question"; choiceQuestion = choice.display_name; } UIUtil.SetLabelValue(labelDisplayItemTitle, choiceTitle); UIUtil.SetLabelValue(labelDisplayItemQuestion, choiceQuestion); } }
public void ShowOverview() { HideStates(); containerOverview.Show(); ShowCamera(); ShowLoaderSpinner(); UpdateOverviewWorld(); if (containerLoader.Has <GameObjectImageFill>()) { GameObjectImageFill fill = containerLoader.Get <GameObjectImageFill>(); fill.Reset(); } // Update team display //LogUtil.Log("ShowOverview:"); flowState = AppOverviewFlowState.GeneralTips; UIPanelDialogBackground.ShowDefault(); UIUtil.SetLabelValue(labelOverviewType, AppContentStates.Current.display_name); AnimateInBottom(containerOverview); UIColors.UpdateColors(); InvokeRepeating("ShowOverviewTip", 0, 15); }
public void UpdateResultItemData() { LogUtil.Log("UIPanelModeTypeChoice:UpdateResultItemData"); UIUtil.SetLabelValue(labelResultItemStatus, GetStatusItemProgress()); UIColors.UpdateColors(); AppContentChoice choice = GetCurrentChoice(); string typeValue = "CORRECT"; string codeValue = "FALSE"; if (isCorrect) //currentChoiceData.CheckChoices(true)) { { UIColors.UpdateColor(containerChoiceResultItem, UIColors.colorGreen); typeValue = "CORRECT!"; GameAudioController.PlaySoundPlayerActionGood(); choicesCorrect += 1; } else { UIColors.UpdateColor(containerChoiceResultItem, UIColors.colorRed); typeValue = "INCORRECT..."; GameAudioController.PlaySoundPlayerActionBad(); } foreach (AppContentChoiceItem choiceItem in choice.choices) { if (choiceItem != null) { if (choiceItem.IsTypeCorrect()) { codeValue = choiceItem.display; } } } if (choice != null) { string choiceResultType = typeValue; string choiceResultValue = codeValue; string choiceResultDescription = choice.description; string choiceResultDisplayName = choice.display_name; if (choice != null) { //choiceQuestion = choice.display_name + choice.code; } UIUtil.SetLabelValue(labelResultItemChoiceDisplayName, choiceResultDisplayName); UIUtil.SetLabelValue(labelResultItemChoiceDescription, choiceResultDescription); UIUtil.SetLabelValue(labelResultItemChoiceResultValue, choiceResultValue); UIUtil.SetLabelValue(labelResultItemChoiceResultType, choiceResultType); } }
// DISPLAY ITEM public void ShowDisplayItem() { LogUtil.Log("UIPanelModeTypeChoice:ShowDisplayItem"); HideStates(); StartCoroutine(ShowDisplayItemCo()); UIColors.UpdateColors(); }
public void ShowContent() { UIPanelDialogBackground.ShowDefault(); AnimateInBottom(containerContent); ContentPause(); UIColors.UpdateColors(); }
public void ShowOverview() { HideStates(); UIPanelDialogBackground.ShowDefault(); //LogUtil.Log("UIPanelModeTypeChoice:ShowOverview:flowState:" + flowState); AnimateInBottom(containerChoiceOverview); ContentPause(); UIColors.UpdateColors(); }
public void ShowOverview() { HideStates(); flowState = AppOverviewFlowState.Mode; UIPanelDialogBackground.ShowDefault(); UIUtil.SetLabelValue(labelOverviewType, AppContentStates.Current.display_name); AnimateInBottom(containerOverview); ContentPause(); UIColors.UpdateColors(); }
IEnumerator ShowDisplayItemCo() { yield return(new WaitForEndOfFrame()); UIPanelDialogBackground.ShowDefault(); //LogUtil.Log("UIPanelModeTypeChoice:ShowDisplayItem:flowState:" + flowState); AnimateInBottom(containerChoiceDisplayItem); loadDataChoice(); UIColors.UpdateColors(); ContentPause(); }
public void ShowTips() { HideStates(); flowState = AppOverviewFlowState.GeneralTips; UIPanelDialogBackground.ShowDefault(); UIUtil.SetLabelValue(labelOverviewType, AppContentStates.Current.display_name); //LogUtil.Log("UIPanelModeTypeChoice:ShowOverview:flowState:" + flowState); AnimateInBottom(containerOverviewGameplayTips); UIColors.UpdateColors(); }
public void ShowOverview() { HideStates(); // Update team display //LogUtil.Log("ShowOverview:"); flowState = AppOverviewFlowState.Mode; UIPanelDialogBackground.ShowDefault(); UpdateOverviewWorld(); UIUtil.SetLabelValue(labelOverviewType, AppContentStates.Current.display_name); AnimateInBottom(containerOverview); GameCustomController.BroadcastCustomSync(); foreach (GameCustomPlayer customPlayer in gameObject.GetList <GameCustomPlayer>()) { if (customPlayer.isActorTypeEnemy) { GameTeam team = GameTeams.Current; if (team != null) { UIUtil.SetLabelValue(labelOverviewTeamEnemy, team.display_name); GameCustomCharacterData customInfo = new GameCustomCharacterData(); customInfo.actorType = GameCustomActorTypes.enemyType; customInfo.presetColorCode = team.data.GetColorPreset().code; customInfo.presetTextureCode = team.data.GetTexturePreset().code; customInfo.type = GameCustomTypes.teamType; customInfo.teamCode = team.code; customPlayer.Load(customInfo); } } } ContentPause(); UIColors.UpdateColors(); }
public void ShowOverview() { HideStates(); containerOverview.Show(); ShowCamera(); // Update team display //LogUtil.Log("ShowOverview:"); flowState = AppOverviewFlowState.GeneralTips; UIPanelDialogBackground.ShowDefault(); UIUtil.SetLabelValue(labelOverviewType, AppContentStates.Current.display_name); AnimateInBottom(containerOverview); UIColors.UpdateColors(); InvokeRepeating("ShowOverviewTip", 0, 15); }
public void UpdateDisplayStateResultsData() { LogUtil.Log("UIPanelModeTypeChoice:UpdateDisplayStateResultsData"); UIColors.UpdateColors(); UIUtil.SetLabelValue(labelResultsStatus, "Results"); GameAudioController.PlaySoundPlayerActionGood(); //double timeCompleted = 30; // TODO double coins = 500; double choiceTotal = choices.Count; double choicesResult = choicesCorrect / choiceTotal; coins = choicesCorrect * 100; string scoreFractionValue = string.Format("{0}/{1}", choicesCorrect, choiceTotal); string scorePercentageValue = choicesResult.ToString("P0"); //string scoreTitleValue = ; //string scoreTypeValue = "4/5"; string scoreCoinsValue = coins.ToString("N0"); UIUtil.SetSliderValue(sliderScore, choicesResult); UIUtil.SetLabelValue(labelResultsScoreFractionValue, scoreFractionValue); UIUtil.SetLabelValue(labelResultsScorePercentageValue, scorePercentageValue); //UIUtil.SetLabelValue(labelResultsTitle, choiceResultValue); //UIUtil.SetLabelValue(labelResultsType, choiceResultType); UIUtil.SetLabelValue(labelResultsCoinsValue, scoreCoinsValue); // REWARDS GameProfileRPGs.Current.AddCurrency(coins); GamePlayerProgress.SetStatCoins(coins); GamePlayerProgress.SetStatCoinsEarned(coins); double xpEarned = coins * 2; GamePlayerProgress.SetStatXP(xpEarned); GameProfileCharacters.Current.CurrentCharacterAddGamePlayerProgressXP(xpEarned); GameProfileCharacters.Current.CurrentCharacterAddGamePlayerProgressEnergy(1f); // refill GameProfileCharacters.Current.CurrentCharacterAddGamePlayerProgressHealth(1f); // refill GameController.ProcessLevelStats(); /* * AppContentChoice choice = GetCurrentChoice(); * * if(choice != null) { * * string choiceTitle = "Loading..."; * string choiceQuestion = "Loading..."; * * if(choice != null) { * choiceTitle = "Question"; * choiceQuestion = choice.display_name + choice.code; * } * * UIUtil.SetLabelValue(labelDisplayItemTitle, choiceTitle); * UIUtil.SetLabelValue(labelDisplayItemQuestion, choiceQuestion); * } */ }