I’ve got a straight road, which is mainly empty. I want to spawn traffic on this road and for the space occupied by each car to be area class: null, so that pathfinding AI cannot travel in spaces occupied by a car.
I’ve modified the collision of my traffic (using the method shown here: https://youtu.be/7LaazCv4rB0?t=680) and I’ve reduced the tile size and increased the cell size.
I’m finding that only the area around my player is being updated, and the area is very small so AIs around me often do not reach an updated section of the navmesh and so trespass into the traffic.
What I’m after is a really simplified dynamic navmesh generation. There’s some conditions that might simplify the matter:
- Traffic is always the same size.
- The player only travels forwards (some steering is allowed but it’s confined to a narrow road).
- Once the player has passed a section of navmesh, it is no longer important.
Are there any methods I could use to affect only the area around my Player and generate very quicly?