Browse Source

Naming convention update

feature-config-parsing2
MagicBot 4 months ago
parent
commit
adb10e34f3
  1. 4
      src/engine/wpak/EffectEntry.java
  2. 8
      src/engine/wpak/EffectsParser.java

4
src/engine/wpak/EffectEntry.java

@ -13,8 +13,8 @@ import java.util.HashMap; @@ -13,8 +13,8 @@ import java.util.HashMap;
import java.util.HashSet;
public class EffectEntry {
public String id;
public String name;
public String effect_id;
public String effect_name;
public int icon;
public HashSet<String> sources = new HashSet<>();
public ArrayList<EffectModifier> mods = new ArrayList<>();

8
src/engine/wpak/EffectsParser.java

@ -43,7 +43,7 @@ public class EffectsParser { @@ -43,7 +43,7 @@ public class EffectsParser {
while (matcher.find()) {
EffectEntry effectEntry = parseEffectEntry(matcher.group());
effect_data.put(effectEntry.id, effectEntry);
effect_data.put(effectEntry.effect_id, effectEntry);
}
}
@ -73,9 +73,9 @@ public class EffectsParser { @@ -73,9 +73,9 @@ public class EffectsParser {
while (matcher.find())
effectHeader.add(matcher.group().trim());
effectEntry.id = effectHeader.get(0);
effectEntry.name = effectHeader.get(1);
effectEntry.name = effectEntry.name.replaceAll("\"", "");
effectEntry.effect_id = effectHeader.get(0);
effectEntry.effect_name = effectHeader.get(1);
effectEntry.effect_name = effectEntry.effect_name.replaceAll("\"", "");
// Some effect mods have no icon
// (SEEINVIS-SHADE "See Invis")

Loading…
Cancel
Save