コード例 #1
0
ファイル: DialogBox.cs プロジェクト: TheHumanBuilders/journey
        //---------------------------------------------------------------------
        // Decision Making
        //---------------------------------------------------------------------

        /// <summary>
        /// If the next node is a decision node, then this will display those
        /// decisions to the user.
        /// </summary>
        private void TryListDecisions()
        {
            var node = DialogManager.GetCurrentNode();

            if (node != null)
            {
                node = node.GetNextNode();

                if (node is DecisionNode decisions)
                {
                    ListDecisions(decisions);
                    DialogManager.SetCurrentNode(node);
                }
                else
                {
                    DialogManager.SetCurrentNode(node, false);
                }
            }
        }