Browse Source

More parsing work

combat-2
MagicBot 9 months ago
parent
commit
0a39102b08
  1. 4
      src/engine/objects/ItemTemplate.java

4
src/engine/objects/ItemTemplate.java

@ -212,7 +212,7 @@ public class ItemTemplate {
JSONArray attack_anim_right = (JSONArray) item_weapon.get("weapon_attack_anim_right"); JSONArray attack_anim_right = (JSONArray) item_weapon.get("weapon_attack_anim_right");
if (attack_anim_right.isEmpty() == false) if (attack_anim_right.isEmpty() == false)
for (Object o : weapon_damage) { for (Object o : attack_anim_right) {
JSONArray animationEntry = (JSONArray) o; JSONArray animationEntry = (JSONArray) o;
int animation = (int) animationEntry.get(0); int animation = (int) animationEntry.get(0);
int duration = (int) animationEntry.get(1); int duration = (int) animationEntry.get(1);
@ -222,7 +222,7 @@ public class ItemTemplate {
JSONArray attack_anim_left = (JSONArray) item_weapon.get("weapon_attack_anim_left"); JSONArray attack_anim_left = (JSONArray) item_weapon.get("weapon_attack_anim_left");
if (attack_anim_left.isEmpty() == false) if (attack_anim_left.isEmpty() == false)
for (Object o : weapon_damage) { for (Object o : attack_anim_left) {
JSONArray animationEntry = (JSONArray) o; JSONArray animationEntry = (JSONArray) o;
int animation = (int) animationEntry.get(0); int animation = (int) animationEntry.get(0);
int duration = (int) animationEntry.get(1); int duration = (int) animationEntry.get(1);

Loading…
Cancel
Save