Exemplo n.º 1
0
        public void doTalk()
        {
            if (dialogId == -1)
            {
                return;
            }

            string str = SvrNPCConfig.instance.get_dialog(dialogId);

            if (str == "")
            {
                return;
            }

            if (dTalk.ContainsKey(dialogId))
            {
                curTalkDta = dTalk[dialogId];
            }
            else
            {
                TalkMainData d = new TalkMainData();
                d.init(str, _npcid.ToString(), viewInfo["name"]);
                dTalk[dialogId] = d;
                curTalkDta      = d;
            }
            curTalkDta.beginTalk(this);
        }
Exemplo n.º 2
0
        public void doTalk()
        {
            bool flag = this.dialogId == -1;

            if (!flag)
            {
                string text  = SvrNPCConfig.instance.get_dialog(this.dialogId);
                bool   flag2 = text == "";
                if (!flag2)
                {
                    bool flag3 = LGAvatarNpc.dTalk.ContainsKey(this.dialogId);
                    if (flag3)
                    {
                        this.curTalkDta = LGAvatarNpc.dTalk[this.dialogId];
                    }
                    else
                    {
                        TalkMainData talkMainData = new TalkMainData();
                        talkMainData.init(text, this._npcid.ToString(), this.viewInfo["name"]);
                        LGAvatarNpc.dTalk[this.dialogId] = talkMainData;
                        this.curTalkDta = talkMainData;
                    }
                    this.curTalkDta.beginTalk(this);
                }
            }
        }