Browse Source

enemy/notEnemy fix for mobs

master
FatBoy-DOTC 2 years ago
parent
commit
ed1a6192c7
  1. 1
      src/engine/Enum.java
  2. 8
      src/engine/objects/Mob.java

1
src/engine/Enum.java

@ -50,7 +50,6 @@ public class Enum { @@ -50,7 +50,6 @@ public class Enum {
}
public enum MonsterType implements EnumBitSetHelper<MonsterType> {
None,
Aelfborn,
All,
Animal,

8
src/engine/objects/Mob.java

@ -1718,10 +1718,12 @@ public class Mob extends AbstractIntelligenceAgent { @@ -1718,10 +1718,12 @@ public class Mob extends AbstractIntelligenceAgent {
Logger.error("Null equipset returned for uuid " + currentID);
this.equip = new HashMap<>(0);
}
// Combine mobbase and mob aggro arrays into one bitvector
this.notEnemy.addAll(this.getMobBase().notEnemy);
this.enemy.addAll(this.getMobBase().enemy);
if(this.getMobBase().notEnemy.size() > 0)
this.notEnemy.addAll(this.getMobBase().notEnemy);
if(this.getMobBase().enemy.size() > 0)
this.enemy.addAll(this.getMobBase().enemy);
try {
NPCManager.applyRuneSetEffects(this);

Loading…
Cancel
Save