End portals storage

This commit is contained in:
paulevsGitch 2021-02-19 17:38:39 +03:00
parent fb7cee1889
commit ee4c4aed73
3 changed files with 118 additions and 0 deletions

View file

@ -69,6 +69,11 @@ public class JsonFactory {
}
}
public static int getInt(JsonObject object, String member, int def) {
JsonElement elem = object.get(member);
return elem == null ? def : elem.getAsInt();
}
public static float getFloat(JsonObject object, String member, float def) {
JsonElement elem = object.get(member);
return elem == null ? def : elem.getAsFloat();