diff --git a/src/engine/wpak/PowerActionParser.java b/src/engine/wpak/PowerActionParser.java index 9b16a721..73993fb9 100644 --- a/src/engine/wpak/PowerActionParser.java +++ b/src/engine/wpak/PowerActionParser.java @@ -82,23 +82,25 @@ public class PowerActionParser { switch (powerActionEntry.action_type) { case "RemoveEffect": - powerActionEntry.effect_id = headerIterator.next(); + effectDescription = new EffectDescription(); + effectDescription.effect_id = headerIterator.next(); + powerActionEntry.effects.add(effectDescription); break; case "CreateMob": - powerActionEntry.arg1 = Integer.parseInt(headerIterator.next()); - powerActionEntry.arg2 = Integer.parseInt(headerIterator.next()); + powerActionEntry.petLevel = Integer.parseInt(headerIterator.next()); + powerActionEntry.petRace = Integer.parseInt(headerIterator.next()); break; case "DamageOverTime": - powerActionEntry.effect_id = headerIterator.next(); - powerActionEntry.arg1 = Integer.parseInt(headerIterator.next()); - powerActionEntry.arg2 = Integer.parseInt(headerIterator.next()); + effectDescription = new EffectDescription(); + effectDescription.effect_id = headerIterator.next(); + effectDescription.cycleDuration = Integer.parseInt(headerIterator.next()); + effectDescription.cycleDelay = Integer.parseInt(headerIterator.next()); + powerActionEntry.effects.add(effectDescription); break; case "Transform": case "Invis": - powerActionEntry.effect_id = headerIterator.next(); - powerActionEntry.arg1 = Integer.parseInt(headerIterator.next()); - break; case "ApplyEffect": + case "ApplyEffects": case "DeferredPower": case "DirectDamage": while (headerIterator.hasNext()) { @@ -143,7 +145,7 @@ public class PowerActionParser { powerActionEntry.scaleFactor.add(Float.parseFloat(bodyPart)); break; case "ISRESISTABLE": - powerActionEntry.isResistable = Boolean.parseBoolean(lineValues[1].trim()); + powerActionEntry.isResistible = Boolean.parseBoolean(lineValues[1].trim()); break; case "ISAGGRESSIVE": powerActionEntry.isAggressive = Boolean.parseBoolean(lineValues[1].trim()); diff --git a/src/engine/wpak/data/EffectDescription.java b/src/engine/wpak/data/EffectDescription.java index ed6664b5..1dadc45b 100644 --- a/src/engine/wpak/data/EffectDescription.java +++ b/src/engine/wpak/data/EffectDescription.java @@ -12,4 +12,6 @@ public class EffectDescription { public String effect_id; public int level; public String message; + public int cycleDuration; + public int cycleDelay; } diff --git a/src/engine/wpak/data/PowerActionEntry.java b/src/engine/wpak/data/PowerActionEntry.java index 0c2e288b..f6299ef1 100644 --- a/src/engine/wpak/data/PowerActionEntry.java +++ b/src/engine/wpak/data/PowerActionEntry.java @@ -25,16 +25,15 @@ public class PowerActionEntry { public boolean shouldShowWeapons = false; public boolean shouldShowArmor = false; public boolean bladeTrails = false; - public boolean isResistable = false; - public String effect_id; + public boolean isResistible = false; public ArrayList scaleFactor = new ArrayList<>(); public ArrayList attackAnimations = new ArrayList<>(); public boolean isAggressive; public mbEnums.DamageType damageType; public boolean applyEffectBlank = false; public boolean wearOffEffectBlank = false; - public int arg1; // used in DamageOverTime, CreateMob, etc. - public int arg2; + public int petLevel; + public int petRace; public boolean removeAll; }