/// <summary> /// Get rigidbody of the colliding game object and add to the list /// </summary> protected void OnTriggerEnter(Collider col) { Rigidbody rigidbody = col.gameObject.GetComponent <Rigidbody>(); if (rigidbody != null) { rigidbodies.Add(rigidbody); empty = false; if (col.CompareTag("Player")) { StartCurrentParticles(); smoothCamera.SetCurrentState(true, particleDirection); playerInCurrent = true; } } }