From 12f8139d1ea08cd25301fe77eab4034e43a6fc87 Mon Sep 17 00:00:00 2001 From: MagicBot Date: Mon, 19 Aug 2024 08:08:32 -0400 Subject: [PATCH] More PowerEntry parsing work. --- src/engine/wpak/PowersParser.java | 6 ++++++ src/engine/wpak/data/PowerEntry.java | 3 +++ 2 files changed, 9 insertions(+) diff --git a/src/engine/wpak/PowersParser.java b/src/engine/wpak/PowersParser.java index 60d8b06c..e4e8323d 100644 --- a/src/engine/wpak/PowersParser.java +++ b/src/engine/wpak/PowersParser.java @@ -255,6 +255,12 @@ public class PowersParser { powerEntry.pulseCycle = Integer.parseInt(arguments[0]); powerEntry.pulseDuration = Integer.parseInt(arguments[1]); break; + case "MAXNUMMOBTARGETS": + powerEntry.maxMobTargets = Integer.parseInt(lineValues[1].trim()); + break; + case "MAXNUMPLAYERTARGETS": + powerEntry.maxPlayerTargets = Integer.parseInt(lineValues[1].trim()); + break; default: Logger.error("Unhandled variable type:" + key + " for power: " + powerEntry.power_id); } diff --git a/src/engine/wpak/data/PowerEntry.java b/src/engine/wpak/data/PowerEntry.java index b35785fa..c07605fd 100644 --- a/src/engine/wpak/data/PowerEntry.java +++ b/src/engine/wpak/data/PowerEntry.java @@ -56,5 +56,8 @@ public class PowerEntry { public boolean sticky = false; public int pulseCycle; public int pulseDuration; + public int maxMobTargets; + public int maxPlayerTargets; + }