public void InitCameraParams() { CamRatio.SetupCamera(this._camera, 0f); GameObject gameObject = GameObject.FindGameObjectWithTag("SpawnPoint"); CameraParams component = gameObject.GetComponent <CameraParams>(); this._camera.fieldOfView = component.cameraFov; this._cameraConfiner = SimpleConfiner.Create(component); }
private void Awake() { CamRatio.SetupCamera(this.m_modelCamera, 0f); this.modelRotate = base.GetComponent <ModelRotate>(); this.mgs = new object[] { ClientV2C.sacriviewChangeHero, ClientV2C.propviewChangeSkin, ClientV2C.propviewChangeToggle }; this.Initialize(); this.coroutine = new CoroutineManager(); }
public void ClipCameras(bool clip) { if (clip) { CamRatio.SetupCamera(CameraRoot.Instance.m_uiCamera, 0f); CamRatio.SetupCamera(CameraRoot.Instance.m_uiEffectCamera, 0f); CamRatio.SetupCamera(CameraRoot.Instance.m_battleCamera, 0f); } else { CamRatio.RestoreCamera(CameraRoot.Instance.m_uiCamera); CamRatio.RestoreCamera(CameraRoot.Instance.m_uiEffectCamera); CamRatio.RestoreCamera(CameraRoot.Instance.m_battleCamera); } }
private void Awake() { this.State = PlayState.idle; this.Play = false; this.Loop = false; this.Resource = string.Empty; if (this.hIndex == 0f) { this.hIndex = 1f; } this.vedioRatio = this.wIndex / this.hIndex; this.AdjustAspect(); this.vCamera.depth = (float)(-(float)(2 + this.ID)); CamRatio.SetupCamera(this.vCamera, 0f); }
public static void SetupCameras(Camera[] cams, float expectRatio = 0f) { if (expectRatio == 0f) { expectRatio = 0.5625f; } if (cams == null || cams.Length < 1) { return; } for (int i = 0; i < cams.Length; i++) { CamRatio.SetupCamera(cams[i], expectRatio); } }