- Home /
How do I make an object move out of another object?
https://www.youtube.com/watch?v=6BT9Def3YJI&feature=youtu.be
*Use video as reference
So I am making a game where the maze moves around as you play but sometimes the walls once it has moved around spawn on the player, I have been looking everywhere for a solution to make the player move out of the wall as soon as its inside it similarly to the game example I will have linked below which I made in another engine. In that engine it did this automatically so I know its possible I'm just not sure how with unity.
Answer by BladeSides · Jun 16, 2020 at 03:49 PM
It seems like you are moving the players transform instead of applying force on a rigidbody. Moreover, the maze system shouldn't spawn the boxes around the character. These two things will be enough to fix the game.
Your answer
![](https://koobas.hobune.stream/wayback/20220613001101im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Having difficulties making a block be a death trigger for a ball. 2 Answers
C# Collision Script Not Working 1 Answer
Multiple Cars not working 1 Answer
Distribute terrain in zones 3 Answers
[SOLVED]Problem with 2D Collider 0 Answers