46
DF Dwarf Mode Discussion / Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« on: April 16, 2014, 12:32:17 am »It's even easier if the terrain is broken up into intranavigable regions. The first step of pathfinding should be to see if the starting tile is in the same region as the ending tile. If not, the search can immediately cease without having to spend a zillion processor ticks on the worst case scenario.I just doubled my FPS by de-sealing the caverns - I had a vertical shaft to the magma sea sealing off caverns. There were 3 forgotten beasts waiting for the soldiers. Seems they constantly tried to A* into the fortress bringing down the FPS.
This is the sort of circumstantial fps drain that might quick to fix by e.g. only making them check for a path every 1000 or 10000 ticks once they've failed a few times in a row, but then again, that may be trickier than one might think. And as mentioned, Toady does prefer working on new features unless there's something that makes things completely unplayable.
Of course, then you have the overhead of checking to see whether or not regions are being split/merged every single time a tile is changed.
So slapping a timer on the thing might be best for now. It can wander randomly for a few weeks before trying again.