3 ms·
> the chunk-graph does not change during gameplay We mean the chunk component graph, right? That does technically change, because you can use https://wiki.fac
by alecbenzer 7y ago
> the chunk-graph does not change during gameplay
We mean the chunk component graph, right?
That does technically change, because you can use https://wiki.factorio.com/Landfill https://wiki.factorio.com/Landfill to fill up water and modify which positions a chunk component takes up (and also potentially merge two chunk components), but I think that happens rarely compared to pathfinding.
- shoo 7y ago> chunk component graph yes. thanks for helping to clarify. > > the chunk-graph does not change during gameplay > that does technically change, because you can use landfill to fill up water and modify which positions a chunk component takes up Yep, that might be a dealbreaker. If the terrain only changes from impassable -> passable, not the other way around (e.g. flooding disconnecting bits), then the distances computed for the old map should be valid lower bounds for the distances on the new modified (by landfill) map, so it might be possible to use the old distances as an admissible a* heuristic to guide search to recompute new distances on the new modified map, but that's getting a bit fiddly. This caching is likely the kind of thing that is probably not worth adding to the codebase unless you get a significant performance boost, as it adds a number of constraints from the required assumptions that impede you from changing the game rules in future
- username90 7y agoYou can add walls which biters try to move around. I think they add an extra cost since they don't move around them perfectly, and often they try to attack the thinner parts of the walls.
- falcolas 7y agoNot to mention cliff explosives (for removing the other major landscape-induced impediment). And there are some mods that let you go in the opposite direction, creating cliffs and water.