Scale of map and impacts on vehicle efficiency

To clarify a bit on what the low-hanging fruit for ephmeral map data would be.
Currently if you drive down a straight road, the game generates and stores a rectangle of map data 144 tiles wide and 21 tles tall surrounding your path. This includes tiles that literally have no contents and ones the player doesn’t even see.
We can eliminate almost half of the map chunks by discarding tiles the player never sees (mostly underground, but also sufficiently far into a forest), and we can eliminate another almost half of the map chunks that have no contents (mostly chunks in midair, but also some occasional road and field chunks).
That “almost half” plus “almost half” ends up with us eliminating everything not at ground level, reducing the overhead to ~144 tiles wide but only one tile tall, and sometimes further shrinking that to be as little as ~36 tiles wide instead.

Let’s be slightly more pessimistic and say it shrinks to 60 tiles wide, what’s that look like?
On open ground each tile consists of a terrain data chunk and maybe an item. The real spoiler here is vehicles because they’re actually huge, but let’s ignore that for now. Each terrain tile is represented as a string, they’re run-length encoded when being output, but let’s ignore that (it really doesn’t help for forests anyway) and say 16 bytes per tile, giving us say 60 x 16 x 1000 bytes per km, or 96 KB per km. If you drive say the width of Massachusetts, which is ballpark 300km, that’s ~ 30 MB.
This could be cut even further if we recognize the many, many standard road tiles that spawn with no items and save them in a way that says so, i.e. “Road section running North-South with no contents”.
Factoring in items is a lot harder, they’re pretty sparse on the ground, but also much larger per instance, so you pretty much have to do data analysis to get a good picture. As a wild guess I’d predict that they account for twice as much data as terrain tiles. On roads they’re pretty negligible, on fields verging roads they’re pretty sparse too, but once you get out into the forests the numbers start climbing. So while I can’t estimate the total, I think you can see that if we discard forest map chunks the player never sees, it will greatly reduce our disk overhead. It’s also possible that we treat things a bit differently when autodriving and simply refrain from saving map chunks that never approached within X tiles of the player.

So wild-ass guess, with a couple of tiny changes we should be able to cut save file overhead for open roads to about .5 MB per km.

5 Likes