Shard native can already use standard lua io. functions, but Shard Spring Lua can't. There's nothing I really need this for at the moment, but it seems like something the Shard API should have. AKA it's low-priority.
Load/save would take variables or a table and save them as lua code.
It might be a good or a bad idea to build the Shard version into the filenames, so that there aren't issues with old data being loaded. For the same reason, if it's possible to get a checksum of the game configuration, that could be used to avoid the need to delete outdated files.
This is problematic as it means on the next game, some shards will have differing contents on the filesystem, and behave differently, and since LuaAIs run synced, it'd cause a game desync
Shard native can already use standard lua
io.
functions, but Shard Spring Lua can't. There's nothing I really need this for at the moment, but it seems like something the Shard API should have. AKA it's low-priority.Load/save would take variables or a table and save them as lua code.
It might be a good or a bad idea to build the Shard version into the filenames, so that there aren't issues with old data being loaded. For the same reason, if it's possible to get a checksum of the game configuration, that could be used to avoid the need to delete outdated files.