diff --git a/BauSystem_Main/src/de/steamwar/bausystem/region/loader/PrototypeLoader.java b/BauSystem_Main/src/de/steamwar/bausystem/region/loader/PrototypeLoader.java index a8a0531c..199c2875 100644 --- a/BauSystem_Main/src/de/steamwar/bausystem/region/loader/PrototypeLoader.java +++ b/BauSystem_Main/src/de/steamwar/bausystem/region/loader/PrototypeLoader.java @@ -44,7 +44,7 @@ public class PrototypeLoader { throw new SecurityException(e.getMessage(), e); } - int currentVersion = yapionObject.getPlainValue("@version"); + int currentVersion = yapionObject.getPlainValueOrDefault("@version", -1); if (currentVersion != loadedVersion && loadedVersion != 0) { throw new SecurityException("Version was not the specified version needed."); } diff --git a/BauSystem_Main/src/de/steamwar/bausystem/region/loader/RegionLoader.java b/BauSystem_Main/src/de/steamwar/bausystem/region/loader/RegionLoader.java index 58f2689f..8d78cbf3 100644 --- a/BauSystem_Main/src/de/steamwar/bausystem/region/loader/RegionLoader.java +++ b/BauSystem_Main/src/de/steamwar/bausystem/region/loader/RegionLoader.java @@ -57,7 +57,7 @@ public class RegionLoader { throw new SecurityException(e.getMessage(), e); } - int currentVersion = yapionObject.getPlainValue("@version"); + int currentVersion = yapionObject.getPlainValueOrDefault("@version", -1); if (currentVersion != loadedVersion && loadedVersion != 0) { throw new SecurityException("Version was not the specified version needed."); }