mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-19 09:39:05 +00:00
Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
commit
88bee76f69
4 files changed
+3
-5
No files matched your search
@@ -34,7 +34,7 @@ public class NPCAttackSelector implements IEntitySelector {
|
||||
if (this.npc.ais.directLOS && !this.npc.getEntitySenses().canSee(entity))
|
||||
return false;
|
||||
|
||||
if (!npc.stats.attackInvisible && ((EntityLivingBase) entity).isPotionActive(Potion.invisibility) && npc.getDistanceSqToEntity(entity) < 9)
|
||||
if (!npc.stats.attackInvisible && ((EntityLivingBase) entity).isPotionActive(Potion.invisibility) && !npc.isInRange(entity, 3.0))
|
||||
return false;
|
||||
|
||||
//prevent the npc from going on an endless killing spree
|
||||
|
||||
@@ -823,8 +823,6 @@ public class ScriptEntity<T extends Entity> implements IEntity {
|
||||
entity.hurtResistantTime = ticks;
|
||||
}
|
||||
|
||||
;
|
||||
|
||||
public void setInvisible(boolean invisible) {
|
||||
entity.setInvisible(invisible);
|
||||
}
|
||||
|
||||
@@ -58,7 +58,7 @@ public class ScriptLivingBase<T extends EntityLivingBase> extends ScriptEntity<T
|
||||
entity.maxHurtResistantTime = time;
|
||||
}
|
||||
|
||||
public int setMaxHurtTime() {
|
||||
public int getMaxHurtTime() {
|
||||
return entity.maxHurtResistantTime;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user