How to prevent colliders from passing through each other?

后端 未结 8 1445
天命终不由人
天命终不由人 2020-12-04 20:23

I am having trouble keeping game objects inside of a contained space. When they reach the edge, there is some momentary push back but then they will go right through the wal

8条回答
  •  孤城傲影
    2020-12-04 20:58

    • Edit ---> Project Settings ---> Time ... decrease "Fixed Timestep" value .. This will solve the problem but it can affect performance negatively.

    • Another solution is could be calculate the coordinates (for example, you have a ball and wall. Ball will hit to wall. So calculate coordinates of wall and set hitting process according these cordinates )

提交回复
热议问题