Browse Source

NPCs apply runes from set

feature-region-set
FatBoy-DOTC 1 year ago
parent
commit
5a9f5f2eca
  1. 8
      src/engine/gameManager/NPCManager.java

8
src/engine/gameManager/NPCManager.java

@ -462,7 +462,13 @@ public enum NPCManager { @@ -462,7 +462,13 @@ public enum NPCManager {
public static void applyRunesForNPC(NPC npc){
for(int runeID : _runeSetMap.get(npc.runeSetID)){
RuneBase rb = RuneBase.getRuneBase(runeID);
npc.runes.add(new CharacterRune(rb,npc.getObjectUUID()));
CharacterRune toApply = new CharacterRune(rb,npc.getObjectUUID());
npc.runes.add(toApply);
EffectsBase effectsBase;
for(MobBaseEffects effect : toApply.getRuneBase().getEffectsList()){
effectsBase = PowersManager.getEffectByToken(effect.getToken());
npc.addEffectNoTimer(Integer.toString(effectsBase.getUUID()), effectsBase, effect.getRank(), true);
}
}
}
}

Loading…
Cancel
Save