x


Collisions triggering sporadically at best

I have two objects colliding (bullets and enemies), and I have it set so that the bullets are destroyed when they collide with the enemies.

However, in actuality most just pass through the enemy without triggering a collision. Only a few actually trigger a collision.

Here is a video demonstrating it (the enemies are destroyed once they have been hit twice)

I am quite new to Unity so any help would be appreciated.

more ▼

asked May 08 '12 at 09:27 PM

mathematicool gravatar image

mathematicool
2 1 2

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

1 answer: sort voted first

Are you setting your Collision Detection correctly for your rigid bodies? http://unity3d.com/support/documentation/Components/class-Rigidbody.html

more ▼

answered May 08 '12 at 09:46 PM

kalebmurphy gravatar image

kalebmurphy
35

Yes! It turned out I hadn't attached a rigid body component to the bullets. Silly me. It shall remain a mystery as to why it still worked occasionally.

May 08 '12 at 09:56 PM mathematicool
(comments are locked)
10|3000 characters needed characters left
Your answer
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:

x3739
x2499
x7

asked: May 08 '12 at 09:27 PM

Seen: 338 times

Last Updated: May 08 '12 at 09:56 PM