Esempio n. 1
0
        protected override void Awake()
        {
            base.Awake();

            if (_camera != null)
            {
                CameraPool.Register(this);
            }
        }
Esempio n. 2
0
        protected override void Awake()
        {
            base.Awake();

            CameraPool.Register(this);

            _stateMachine = TypedStateMachine <Camera> .CreateFromParentComponentSource(this.gameObject, false, false);

            _stateMachine.StateChanged += this.OnStateChanged;
        }
Esempio n. 3
0
        private bool AnyNonUnityCamerasContains(Camera c)
        {
            var e = CameraPool.GetEnumerator();

            while (e.MoveNext())
            {
                if (!(e.Current is UnityCamera) && e.Current.Contains(c))
                {
                    return(true);
                }
            }
            return(false);
        }
        protected override void Awake()
        {
            base.Awake();

            //_camera = this.GetComponent<Camera>();
            //if (_camera == null)
            //{
            //    ObjUtil.SmartDestroy(this);
            //}
            //else
            //{
            //    CameraManager.Register(this);
            //}


            if (_camera != null)
            {
                CameraPool.Register(this);
            }
        }
        protected override void OnDestroy()
        {
            base.OnDestroy();

            CameraPool.Unregister(this);
        }
Esempio n. 6
0
 public void ForceSyncTaggedMainCamera()
 {
     _main           = CameraPool.FindTaggedMainCamera();
     _overrideAsNull = false;
 }
Esempio n. 7
0
        protected override void Awake()
        {
            base.Awake();

            CameraPool.Register(this);
        }