There are many ways to do this. One variant is to define walkable areas.
Circular control used for walkable areas control
AreaControl