ZeroK-RTS/Zero-K

Figure out the engine pathing regression settings

GoogleFrog opened this issue · 1 comments

Before:

  • there was a modrule that let units move downhill without a slowdown (otherwise, same slowdown as going uphill). Apparently neither pathfinder (legacy aka HAPFS, nor QTPFS) knew about this so units avoided slopes anyway
    allowDirectionalPathing = true,

After

  • the modrule has been removed and, as far as I can tell, is always "true", i.e. units no longer slow down downhill. Technically this is a regression but all spring/recoil games set it to true anyway; no change for us
  • you can now specify allowDirectionalPathing per movedef. This makes the legacy pathfinder (aka HAPFS, the one we use) know about the lack of slowdown, and it won't avoid downward slopes. This defaults to false so no change for us yet, but this is the new knob to tweak
  • legacy pathfinder does NOT have the other new 'shortest path' feature mentioned below

QTPFS

  • we don't use it so not immediately relevant
  • QTPFS doesn't support directional pathfinding so will still avoid downward slopes regardless of the new movedef directional pathing setting
  • on the other hand QTPFS (but not our legacy HAPFS) has a per-movedef preferShortestPath setting that makes it ignore nonzero speed modifiers (just avoiding obstacles) when deciding where to path.