Ejemplo n.º 1
0
    public void OnChoiceSelected(int targetID, int index)
    {
        switch (state)
        {
        case State.DisplayingMainChoices:
            // Change current node to target node
            m_scenario.Jump(targetID);
            m_scenario.RemoveChoice(index);
            DisableChoices();
            state = State.Processing;
            break;

        case State.DisplayingSimpleChoices:
            SimpleChoiceNode temp = m_scenario.GetCurrentNode() as SimpleChoiceNode;
            m_scenario.AdvanceByNode(temp.GetNextNode(index));
            DisableChoices();
            state = State.Processing;
            break;
        }
    }