|
|
@ -50,8 +50,8 @@ public class ItemTemplate { |
|
|
|
public int item_render_object_female; |
|
|
|
public int item_render_object_female; |
|
|
|
public float item_health_full; |
|
|
|
public float item_health_full; |
|
|
|
public int item_parry_anim_id; |
|
|
|
public int item_parry_anim_id; |
|
|
|
public EnumSet<Enum.CharacterSkills> item_skill_used = EnumSet.noneOf(Enum.CharacterSkills.class); |
|
|
|
public String item_skill_used = ""; |
|
|
|
public EnumSet<Enum.CharacterSkills> item_skill_mastery_used = EnumSet.noneOf(Enum.CharacterSkills.class); |
|
|
|
public String item_skill_mastery_used = ""; |
|
|
|
public float item_bulk_factor; |
|
|
|
public float item_bulk_factor; |
|
|
|
public int item_defense_rating; |
|
|
|
public int item_defense_rating; |
|
|
|
public float item_weapon_wepspeed; |
|
|
|
public float item_weapon_wepspeed; |
|
|
@ -67,7 +67,7 @@ public class ItemTemplate { |
|
|
|
public EnumSet<Enum.ItemFlags> item_flags = EnumSet.noneOf(Enum.ItemFlags.class); |
|
|
|
public EnumSet<Enum.ItemFlags> item_flags = EnumSet.noneOf(Enum.ItemFlags.class); |
|
|
|
public EnumSet<Enum.ItemUseFlags> item_use_flags = EnumSet.noneOf(Enum.ItemUseFlags.class); |
|
|
|
public EnumSet<Enum.ItemUseFlags> item_use_flags = EnumSet.noneOf(Enum.ItemUseFlags.class); |
|
|
|
public int item_initial_charges; |
|
|
|
public int item_initial_charges; |
|
|
|
public HashMap<Enum.CharacterSkills, Integer> item_skill_required = new HashMap<>(); |
|
|
|
public HashMap<String, Integer> item_skill_required = new HashMap<>(); |
|
|
|
public EnumSet<Enum.MonsterType> item_race_req = EnumSet.noneOf(Enum.MonsterType.class); |
|
|
|
public EnumSet<Enum.MonsterType> item_race_req = EnumSet.noneOf(Enum.MonsterType.class); |
|
|
|
public EnumSet<Enum.MonsterType> item_race_res = EnumSet.noneOf(Enum.MonsterType.class); |
|
|
|
public EnumSet<Enum.MonsterType> item_race_res = EnumSet.noneOf(Enum.MonsterType.class); |
|
|
|
|
|
|
|
|
|
|
@ -163,21 +163,13 @@ public class ItemTemplate { |
|
|
|
|
|
|
|
|
|
|
|
Object skill_used = jsonObject.get("item_skill_used"); |
|
|
|
Object skill_used = jsonObject.get("item_skill_used"); |
|
|
|
|
|
|
|
|
|
|
|
if (skill_used instanceof String) { |
|
|
|
if (skill_used instanceof String) |
|
|
|
String skilString = (String) skill_used; |
|
|
|
item_skill_used = (String) skill_used; |
|
|
|
skilString = skilString.replaceAll("\\s", ""); |
|
|
|
|
|
|
|
skilString = skilString.replaceAll(",", ""); |
|
|
|
|
|
|
|
item_skill_used.add(Enum.CharacterSkills.valueOf(skilString)); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Object mastery_used = jsonObject.get("item_skill_mastery_used"); |
|
|
|
Object mastery_used = jsonObject.get("item_skill_mastery_used"); |
|
|
|
|
|
|
|
|
|
|
|
if (mastery_used instanceof String) { |
|
|
|
if (mastery_used instanceof String) |
|
|
|
String masteryString = (String) mastery_used; |
|
|
|
item_skill_mastery_used = (String) mastery_used; |
|
|
|
masteryString = masteryString.replaceAll("\\s", ""); |
|
|
|
|
|
|
|
masteryString = masteryString.replaceAll(",", ""); |
|
|
|
|
|
|
|
item_skill_mastery_used.add(Enum.CharacterSkills.valueOf(masteryString)); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
item_parry_anim_id = ((Long) jsonObject.get("item_parry_anim_id")).intValue(); |
|
|
|
item_parry_anim_id = ((Long) jsonObject.get("item_parry_anim_id")).intValue(); |
|
|
|
|
|
|
|
|
|
|
@ -258,10 +250,8 @@ public class ItemTemplate { |
|
|
|
for (Object o : skill_required) { |
|
|
|
for (Object o : skill_required) { |
|
|
|
JSONObject skill_req = (JSONObject) o; |
|
|
|
JSONObject skill_req = (JSONObject) o; |
|
|
|
String skill_type = (String) skill_req.get("skill_type"); |
|
|
|
String skill_type = (String) skill_req.get("skill_type"); |
|
|
|
skill_type = skill_type.replaceAll("\\s", ""); |
|
|
|
|
|
|
|
skill_type = skill_type.replaceAll(",", ""); |
|
|
|
|
|
|
|
int skill_level = ((Long) skill_req.get("skill_level")).intValue(); |
|
|
|
int skill_level = ((Long) skill_req.get("skill_level")).intValue(); |
|
|
|
item_skill_required.put(Enum.CharacterSkills.valueOf(skill_type), skill_level); |
|
|
|
item_skill_required.put(skill_type, skill_level); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
JSONObject race_required = (JSONObject) jsonObject.get("item_race_req"); |
|
|
|
JSONObject race_required = (JSONObject) jsonObject.get("item_race_req"); |
|
|
|