- Home /
Collision 2d is not working perfectly
Hey all, I am trying to make a game like air hockey, and moving my sprite using mouse all the things are working perfectly except collision. i.e when ever the hockey strikes the board wall some times collision is detected but some time hockey just passed the wall without ever get collision.
Can any one help me to fix this bug
Thanks
no i was using rigid body not the transform.position
$$anonymous$$aybe the wall is too thin and in the time between updates the object manages to get out. Try to change the collision detection from discrete to continuous on the rigidbody2D component. You can look up what that means here.
Your answer
Follow this Question
Related Questions
2D physics settings for solid 2D objects with polygon collider 0 Answers
Why do two colliders cross at high force? 0 Answers
Why Rigidbody2D gameobject automatically translating to Vector2.zero itself 1 Answer
Unity Physics2D.OverlapAreaAll not picking up any colliders 0 Answers
What oject/method calls "OnCollisionEnter2D"?,What object/method calls "OnCollisionEnter2D"? 0 Answers