Browse Source

Support for multiple pre-reqs

feature-config-parsing2
MagicBot 4 months ago
parent
commit
2fb7260077
  1. 2
      src/engine/wpak/PowersParser.java

2
src/engine/wpak/PowersParser.java

@ -196,7 +196,6 @@ public class PowersParser {
powerEntry.curves.put(arguments.get(0), mbEnums.CompoundCurveType.valueOf(arguments.get(1))); powerEntry.curves.put(arguments.get(0), mbEnums.CompoundCurveType.valueOf(arguments.get(1)));
break; break;
case "EQPREREQ": case "EQPREREQ":
EquipmentPreReq equipmentPreReq = new EquipmentPreReq();
matcher1 = STRSPLIT_REGEX.matcher(lineValues.get(1).trim()); matcher1 = STRSPLIT_REGEX.matcher(lineValues.get(1).trim());
arguments = new ArrayList<>(); arguments = new ArrayList<>();
@ -206,6 +205,7 @@ public class PowersParser {
argumentIterator = arguments.iterator(); argumentIterator = arguments.iterator();
while (argumentIterator.hasNext()) { while (argumentIterator.hasNext()) {
EquipmentPreReq equipmentPreReq = new EquipmentPreReq();
equipmentPreReq.slot = mbEnums.EquipSlotType.valueOf(arguments.get(0)); equipmentPreReq.slot = mbEnums.EquipSlotType.valueOf(arguments.get(0));
equipmentPreReq.skill = arguments.get(1).replaceAll("\"", ""); equipmentPreReq.skill = arguments.get(1).replaceAll("\"", "");
equipmentPreReq.required = Integer.parseInt(arguments.get(2)); equipmentPreReq.required = Integer.parseInt(arguments.get(2));

Loading…
Cancel
Save