OnCollisionEnter not working for me (C#)

I am trying to override OnCollisionEnter() and attach it to a box with ridigbody physics.
But am keep getting this error -

Script error: OnCollisionEnter
This message parameter has to be of type: Collision
The message will be ignored.

Here’s my code -

void OnCollisionEnter(Collision collision)
{
}

yes even this blank method is failing

I copypasted that code and it works fine, assuming it’s in a MonoBehaviour class. Not sure what you mean by “trying to override OnCollisionEnter()” though.

–Eric

Have you defined another class called Collision?

thnx Bren ya i had an another class named Collison in a different script but i renamed it to something else and it worked.
Finally i made my cheap portal in unity demo working will post a video in sometime. (I just followed twisted brothers tutorials and made a small game app and implemented portals just for fun)