- Home /
Collision detection in .fbx
I am new to unity . I have created two .fbx animation and imported it into the unity. I have also added simple walk script into it. They its all work fine. Now i want that when both these objects collide with each other then they can't cross each other and a sound will produce..How to do this..Is there any help for this...THanks in advnce
How do they move ? Translate ? Character Controller ? Rigidbody ?
I think you can stop playing animation upon collision (using OnCollisionEnter())
through transform they move..i am using this code
var farword=Input.Get$$anonymous$$ey("up");
if(farword==true)
{
animation.Play("ArmatureAction");
}
transform.Translate(0,0,Input.GetAxis("Vertical"));
transform.Rotate(0,Input.GetAxis("Horizontal"),0);
Answer by Schneider21 · Feb 15, 2015 at 06:20 AM
Generally, animated objects should not use mesh colliders. Instead, use primitive colliders attached to the bones, or just one capsule collider if you can get away with it.