Moving entity alongside other entity

Hello, I want snap entity to on collision to the wall and move alongside it on one axis. and When collision ends entity goes back to normal mouse movement.
Something like in this example: Screen Recording 2022-11-22 at 4.30.06 - Google Drive

Thanks for any help!

Hmm, this is a tough one that I don’t have a good answer for.

Assuming you are using kinematic rigidbody for the chair, you can check for collision contacts to the wall, find the normal of the wall somehow and offset the chair from the contact point on the wall, along the wall normal.

1 Like