예제 #1
0
파일: WarUI.cs 프로젝트: wxl-007/ShadowDota
        void OnEnable()
        {
            WarClientNpcMgr mgr = WarClientManager.Instance.npcMgr;

            if (mgr != null)
            {
                mgr.createUIForNpc = CreateUIForNpc;
            }
            EasyJoystick.On_JoystickTouchStart += On_JoystickStart;
            EasyJoystick.On_JoystickMove       += On_JoystickMove;
            EasyJoystick.On_JoystickTouchUp    += On_JoystickMoveEnd;
        }
예제 #2
0
        /// <summary>
        /// 战斗的入口在这里
        /// </summary>
        void Awake()
        {
            Instance         = this;
            mainCameraFollow = Main3DCamera.GetComponent <CameraFollow>();

            ///
            /// 获得NPC管理容器
            ///
            npcMgr = new WarClientNpcMgr();
            npcMgr.Init();
            //初始化场景的创建器
            creator = new ClientCreator(this);

            Shake      = Main3DCamera.GetComponent <ShakeCamera>();
            AutoBattle = false;
        }