public void OnCollisionEnter(Collision col){
if (col.gameObject.CompareTag("Player")) {
Destroy (this.gameObject);
Debug.Log ("Exp Earned");
}
}
I'm getting incredibly frustrated about this. I've typed this same code millions of times over in other scripts and no problem. It's attached to a sphere with a rigidbody and a sphere collider. I'm using ufps controller. It should work, but it just doesn't. I end up just on top of the orb. I have no idea what is wrong with it
↧