Extra Hard Mode

Extra Hard Mode

63.1k Downloads

Pigmen deal no damage for other worlds when whitelist is used

zhro opened this issue ยท 3 comments

commented

I am currently using EHM by whitelisting it for specific worlds:

  Enabled Worlds:
  - someworld

This is causing other worlds where it is not enabled to have pigmen which deal no damage.

I have pigmen configured as such:

  PigZombies:
    Always Angry: true
    # This simple multiplier allows you to reduce the damage of PigZombies. They are a bit too tough otherwise.
    Dmg to players percent: 70
    # Add netherwart to the drops of pigzombies.
    Always Drop Netherwart In Fortresses: true
    Percent Chance to Drop Netherwart Elsewhere In Nether: 25
    Spawn on Lighting Strikes:
      Enable: true
commented

Latest EHM 3.10, latest Spigot 1.11.2. Tested on a non-whitelisted server and a whitelisted server (as described). Disabling EHM made pigmen do damage and re-enabling it caused damage to again stop on non-whitelisted worlds.

commented

version? spigot version?

commented

event.setDamage(event.getDamage() * CFG.getInt(RootNode.PIG_ZOMBIE_DMG_PERCENT, event.getEntity().getWorld().getName()) / 100);

Should do a world check before deciding to set damage, or check if getInt is greater than 0. Pretty sure that getInt is returning 0.