[v1.3.0+, EoR] Ruined Cave Floor Sort
Posted: Sat Apr 01, 2017 2:02 am
Does it vaguely annoy anyone else that the Ruined Cave in EoR doesn't auto-sort stuff that you drop on the floor the way the fortress storage room does? `Coz I'm fiddling with an addon to add that functionality, and I figured I'd get some feedback before I committed to anything.
See, the slightly tricky bit is that since the Cave isn't a nice rectangle like the storage room, there's no immediately obvious order of grids to sort stuff to as you drop it. For a first pass, the sequence I'm going with for dropping, say, a dagger, is:

See, the slightly tricky bit is that since the Cave isn't a nice rectangle like the storage room, there's no immediately obvious order of grids to sort stuff to as you drop it. For a first pass, the sequence I'm going with for dropping, say, a dagger, is:
- If there was already a pile of daggers on the grid, leave the dagger there.
- Otherwise, search for a pile of daggers on all the other floor grids of the Cave, and if we find one, move the dagger there.
- Otherwise, if the grid was empty before we dropped the dagger on it, leave it there.
- Otherwise, if there are any other empty floor grids, move the dagger to the nearest one.
- Otherwise, leave the dagger where you dropped it. (The storage room will pick the dagger up off the floor and put it back in your inventory in this case, but that just seemed odd.)

