void Start() { sound = FindObjectOfType <SoundSpawn>(); player = FindObjectOfType <PlayerController> ().transform; flash = GameObject.Find("PentagramFlash").GetComponent <Flash>(); shaker = FindObjectOfType <CinemachineCameraShaker>(); }
private void Start() { rb = GetComponent <Rigidbody2D>(); light = GetComponent <Light2D>(); light.enabled = false; GetComponent <LightDecay>().enabled = false; shaker = FindObjectOfType <CinemachineCameraShaker>(); lightCollider.SetActive(false); }
/// <summary> /// On awake we grab our components /// </summary> protected virtual void Awake() { Instance = this; _virtualCamera = GameObject.FindObjectOfType <Cinemachine.CinemachineVirtualCamera>(); _perlin = _virtualCamera.GetCinemachineComponent <Cinemachine.CinemachineBasicMultiChannelPerlin>(); }