예제 #1
0
        public override void onClosed()
        {
            closeSubWins();

            if (m_proAvatar != null)
            {
                m_proAvatar.dispose();
                m_proAvatar = null;
            }

            m_handle = null;
            instance = null;
            //if (m_skmesh_camera != null)
            //{
            //    GameObject.Destroy(m_skmesh_camera);
            //    m_skmesh_camera = null;
            //}
            if (m_player_camera != null)
            {
                GameObject.Destroy(m_player_camera);
                m_player_camera = null;
            }
            if (m_npc_camera != null)
            {
                GameObject.Destroy(m_npc_camera);
                m_npc_camera = null;
            }
            if (m_anim_usr != null)
            {
                Destroy(m_selfObj);
                m_selfObj  = null;
                m_anim_usr = null;
            }

            if (m_npc_obj != null)
            {
                Destroy(m_npc_obj.gameObject);
                m_npc_obj = null;
            }
            EventTriggerListener.Get(gameObject).clearAllListener();
            base.onClosed();
            InterfaceMgr.getInstance().changeState(InterfaceMgr.STATE_NORMAL);
        }
예제 #2
0
        public override void onShowed()
        {
            bool flag = joystick.instance != null;

            if (flag)
            {
                joystick.instance.OnDragOut(null);
            }
            dialog.instance = this;
            bool flag2 = dialog.fake_npc != null;

            if (flag2)
            {
                InterfaceMgr.setUntouchable(this.bg);
                this.initAvatar();
                dialog.curDesc = dialog.fake_desc;
                this.OnShowAvatar(true);
                InterfaceMgr.getInstance().open(InterfaceMgr.NPC_TALK, null, false);
            }
            else
            {
                bool flag3 = !dialog.continuedo;
                if (flag3)
                {
                    this.curIdx = 0;
                }
                dialog.continuedo = false;
                InterfaceMgr.setUntouchable(this.bg);
                this.initAvatar();
                this.doNext();
            }
            base.onShowed();
            InterfaceMgr.getInstance().changeState(InterfaceMgr.STATE_STORY);
            bool flag4 = a3_chapter_hint.instance != null && npctalk.instance != null;

            if (flag4)
            {
                npctalk.instance.MinOrMax(false);
            }
        }
예제 #3
0
        public override void onClosed()
        {
            this.closeSubWins();
            dialog.m_handle = null;
            dialog.instance = null;
            bool flag = this.m_player_camera != null;

            if (flag)
            {
                UnityEngine.Object.Destroy(this.m_player_camera);
                this.m_player_camera = null;
            }
            bool flag2 = this.m_npc_camera != null;

            if (flag2)
            {
                UnityEngine.Object.Destroy(this.m_npc_camera);
                this.m_npc_camera = null;
            }
            bool flag3 = this.m_anim_usr != null;

            if (flag3)
            {
                UnityEngine.Object.Destroy(this.m_selfObj);
                this.m_selfObj  = null;
                this.m_anim_usr = null;
            }
            bool flag4 = this.m_anim_npc != null;

            if (flag4)
            {
                UnityEngine.Object.Destroy(this.m_anim_npc.gameObject);
                this.m_anim_npc = null;
            }
            EventTriggerListener.Get(base.gameObject).clearAllListener();
            base.onClosed();
            InterfaceMgr.getInstance().changeState(InterfaceMgr.STATE_NORMAL);
        }
예제 #4
0
        public override void onShowed()
        {
            if (a1_gamejoy.inst_joystick != null)
            {
                a1_gamejoy.inst_joystick.OnDragOut();
            }
            instance = this;
            if (fake_npc != null)
            {
                InterfaceMgr.setUntouchable(bg);
                initAvatar();
                curDesc = fake_desc;
                OnShowAvatar(true);
                InterfaceMgr.getInstance().ui_async_open(InterfaceMgr.NPC_TALK);
            }
            else
            {
                if (!continuedo)
                {
                    curIdx = 0;
                }
                continuedo = false;

                InterfaceMgr.setUntouchable(bg);
                initAvatar();
                // EventTriggerListener.Get(gameObject).onClick = onCLick;
                doNext();
            }


            base.onShowed();
            InterfaceMgr.getInstance().changeState(InterfaceMgr.STATE_STORY);
            if (a3_chapter_hint.instance != null && npctalk.instance != null)
            {
                npctalk.instance.MinOrMax(false);
            }
        }