forked from MagicBane/Server
Both sparse fields parsed
This commit is contained in:
@@ -127,7 +127,7 @@ public class ItemTemplate {
|
|||||||
public int rune_group_role_set;
|
public int rune_group_role_set;
|
||||||
public boolean rune_renderable = false;
|
public boolean rune_renderable = false;
|
||||||
public int rune_natural_power_attack;
|
public int rune_natural_power_attack;
|
||||||
public HashMap<String, Integer> rune_sparse_data = new HashMap<>();
|
public HashMap<String, String> rune_sparse_data = new HashMap<>();
|
||||||
|
|
||||||
public ItemTemplate(JSONObject jsonObject) {
|
public ItemTemplate(JSONObject jsonObject) {
|
||||||
|
|
||||||
@@ -169,7 +169,7 @@ public class ItemTemplate {
|
|||||||
|
|
||||||
for (Object key : obj_sparse_json.keySet()) {
|
for (Object key : obj_sparse_json.keySet()) {
|
||||||
String sparseType = (String) key;
|
String sparseType = (String) key;
|
||||||
String sparseValue = (String) obj_sparse_json.get(key);
|
String sparseValue = (String) obj_sparse_json.get(sparseType);
|
||||||
obj_sparse_data.put(sparseType, sparseValue);
|
obj_sparse_data.put(sparseType, sparseValue);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -499,7 +499,7 @@ public class ItemTemplate {
|
|||||||
|
|
||||||
for (Object key : rune_sparse_json.keySet()) {
|
for (Object key : rune_sparse_json.keySet()) {
|
||||||
String sparseType = (String) key;
|
String sparseType = (String) key;
|
||||||
int sparseValue = ((Long) rune_sparse_json.get("sparseType")).intValue();
|
String sparseValue = (String) rune_sparse_json.get(sparseType);
|
||||||
rune_sparse_data.put(sparseType, sparseValue);
|
rune_sparse_data.put(sparseType, sparseValue);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user