How to solve the situation that the moving position is blocked by the wall

When I set the Player position from A to B, it was blocked by the wall, so I could only move to the red C, but not B correctly. how to solve it?


  • Be sure with these questions to include information that is needed. There is no indication of how you are moving this object. Chances are the CharacterController you are using is designed to not let the character walk through walls.

  • I used CharacterController and NetworkCharacterControllerPrototype sync components.

    set location

    transform.position = bPoint;

  • It may be called in FixedUpdateNetwork

    NetworkCharacterControllerPrototype .Move method,

    At this time, setting transform.position will be blocked by the wall