private void Start() { //spear = spear_go.GetComponent<Spear>(); particle_seek = trail.GetComponent <ParticleSeek>(); pp_volume = Camera.main.GetComponent <PostProcessVolume>(); pp_volume.profile.TryGetSettings(out ca_layer); pp_volume.profile.TryGetSettings(out lens_distortion_layer); pp_volume.profile.TryGetSettings(out vignette_layer); conjure_transition = 1f; }
private void Awake() { rb = GetComponent <Rigidbody>(); localT = gameObject.transform; particles = GetComponent <ParticleSystem>(); meshRenderer = GetComponent <MeshRenderer>(); sphereCollider = GetComponent <SphereCollider>(); orbitParticles = gameObject.transform.GetChild(0).GetComponentInChildren <ParticleSystem>(); orbitObj = orbitParticles.gameObject; orbitSeek = GetComponentInChildren <ParticleSeek>(); collectionFX = GetComponentInChildren <ParticleCollectionFX>(); if (collectionFX != null) { collectionFX.SetAnimationEndedCallback(delegate { Destroy(gameObject); Destroy(orbitObj); }); } }