- Home /
Mesh colliders with rigidbody isn't working
My rigidbody isn't detecting some collisions with mesh colliders(terrain). I'm modifying the transform.position of rigidbody and it is transforming into the terrain. But when I checked convex in mesh collider, it is detecting the collision. Can anyone explain why it isn't working? I believe it is because of modifying transform.position. How can we get around this if we dont want to use Addforce, velocity etc except for modifying transform.position?
Answer by Julien-Lynge · May 31, 2013 at 08:39 PM
Set your rigidbody to kinematic (look up the docs if you don't understand what that is), or use the build-in rigidbody functions. E.g.:
http://docs.unity3d.com/Documentation/ScriptReference/Rigidbody.MovePosition.html
But moveposition just applies speed. I want to teleport the object to certain point.
So you want to teleport it, but you want to hit objects along the way? I'm afraid I don't understand what you're trying to do.
I'm trying activate the objects at the shooting point, but if the shooting point is on the terrain, it is ended up into the terrains. I'm trying to detect those collisions and spawn them on the terrain.
Your answer
Follow this Question
Related Questions
Why I've a gap between meshcolliders? 0 Answers
Convex NonTrigger Mesh Collider + Rigidbody = weird transform position 0 Answers
Object not moving,Object not moving in any direction 1 Answer
Find mesh top - Keep gameobject on top of a mesh 0 Answers
Detect a GameObject Passing Between Other Two GameObjects? 4 Answers