void Start() { blackScreenAnim.GetReferences(); StartCoroutine(blackScreenAnim.anim.PlayBackward(blackScreenAnim, true)); characterAlreadyCame = new List <Character>(); unfoldTime = false; negoceTimeSpend = 0; allPresentCharacters = new List <CharacterHandler>(); if (randomCharacterGenerated > 0) { for (int i = 0; i < randomCharacterGenerated; i++) { allPossibleCharacters.Add(GetRandomGeneratedCharacter()); } } else { } nextCharacterApparitionTime = UnityEngine.Random.Range(5, 8); for (int i = 0; i < playerHandler.allStallObjects.Count; i++) { playerHandler.allStallObjects[i].interestLevelToShow = -1; } notesWindowAnim.GetReferences(); notesWindowAnim.anim.SetAtEndState(notesWindowAnim); askToLeaveButton.SetEnable(true); stallOpeningAnim.GetReferences(); stallOpeningAnim.anim.SetAtStartState(stallOpeningAnim); nextDayButton.SetEnable(false); nextDayButton.GetComponent <CanvasGroup>().alpha = 0; }
public void OpenShop() { StartCoroutine(stallOpeningAnim.anim.Play(stallOpeningAnim)); playerHandler.Speak(playerHandler.welcomeSpeech, 5); unfoldTime = true; openStallButton.SetEnable(false); openStallButton.GetComponent <CanvasGroup>().alpha = 0; }
void OnClicked(SimpleButton button) { Say(button.text); if (clicked) { return; } clicked = true; if (button.text == ok_word) { button.GetComponent <SimpleFeedback>().SetState(SimpleFeedback.states.OK, 2); Invoke("OnCorrect", 1); } else { button.GetComponent <SimpleFeedback>().SetState(SimpleFeedback.states.WRONG, 2); Invoke("ResetLetters", 2); } }
void OnClicked(SimpleButton button) { if (button == null) { return; } if (!canSelect) { return; } canSelect = false; if (IsOk(button.text)) { button.GetComponent <SimpleFeedback>().SetState(SimpleFeedback.states.OK, 60); SetResults(true); button.InactivateFor(60); } else { button.GetComponent <SimpleFeedback>().SetState(SimpleFeedback.states.WRONG, 60); SetResults(false); } // SayAsset(button.text, null); }