Пример #1
0
 private void Start()
 {
     currentState                    = startingState;
     secondaryStates                 = currentState.GetAvailableStates();
     numberOfChoicesAvailable        = secondaryStates.Length;
     backgroundImageComponent.sprite = currentState.GetBackground();
     numberOfDrinks                  = 0;
     UpdateStory();
 }
Пример #2
0
    public void UpdateStory()
    {
        if (!currentState.callsBartender)
        {
            textComponent.text        = currentState.GetStoryText();
            choicesTextComponent.text = currentState.GetChoiceText();
        }

        else if (currentState.callsBartender)
        {
            textComponent.text        = currentState.GetStoryText();
            choicesTextComponent.text = mainChoicesText[numberOfDrinks].GetBarkeepText();
            numberOfDrinks           += 1;
        }

        backgroundImageComponent.sprite = currentState.GetBackground();
    }