Mirroar / hivemind

Fully automated open source AI core for the game screeps. Also usable as an opponent on private servers.
MIT License
29 stars 10 forks source link

Fix inter-room pathfinding across obstacles #34

Open Mirroar opened 3 years ago

Mirroar commented 3 years ago

Very prevalent on the season server because of the highway walls, but even on the normal server this can happen with rooms where old buildings are left behind: The moveToRoom method assumes all exits in a room are reachable. But when this is not the case, it needs to be detected, memorized, and another path might need to be found, if there is one.

Mirroar commented 3 years ago

We might even span some dismantlers to automatically remove such obstacles for easier navigation.

Mirroar commented 3 years ago

The new NavMesh is able to navigate around obstacles, including source keepers. It is used by scouts and for squad movement. Ideally we will convert all inter-room movement to this, as it's much more robust and prevents creeps from dancing at room borders.