Turn logic / Cross-sector production / Pad tweaks

This commit is contained in:
Anuken
2020-05-15 11:03:21 -04:00
parent 603cb4295a
commit b68e0a8562
16 changed files with 188 additions and 39 deletions

View File

@@ -31,7 +31,17 @@ public abstract class SaveVersion extends SaveFileReader{
public SaveMeta getMeta(DataInput stream) throws IOException{
stream.readInt(); //length of data, doesn't matter here
StringMap map = readStringMap(stream);
return new SaveMeta(map.getInt("version"), map.getLong("saved"), map.getLong("playtime"), map.getInt("build"), map.get("mapname"), map.getInt("wave"), JsonIO.read(Rules.class, map.get("rules", "{}")), map);
return new SaveMeta(
map.getInt("version"),
map.getLong("saved"),
map.getLong("playtime"),
map.getInt("build"),
map.get("mapname"),
map.getInt("wave"),
JsonIO.read(Rules.class, map.get("rules", "{}")),
JsonIO.read(Stats.class, map.get("stats", "{}")).productionRates(),
map
);
}
@Override