x


Rigidbody: how to get collisions for the current frame ?

I am trying to make a character controller using a rigidbody, for a sidescroller. The problem is in detecting the collisions. I need a way to get similar result to the character controller unity provides( when it collides on the sides, on top or bottom).

My question: Is there a way to get a list of the colliders my rigidbody is in contact with at the current frame, WITHOUT keeping track of the OnCollisionEnter and OnCollisionStay events ?

If not, how reliable are these events? I am developing for mobile platforms. Is there a possibility that an OncollisionEnter event won't trigger, and get an OnCollisionStay without it?

Also, during a physics frame, what gets calculated first, fixedUpdate or collisions( OnCollision events )?

Thank you for your time, Claudiu

more ▼

asked Feb 24 '12 at 10:10 PM

nikudy gravatar image

nikudy
1 1 1 3

(comments are locked)
10|3000 characters needed characters left

0 answers: sort newest
Be the first one to answer this question
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x2496
x1792
x672

asked: Feb 24 '12 at 10:10 PM

Seen: 240 times

Last Updated: Feb 24 '12 at 10:10 PM