mojira.dev
MC-106765

Silverfish not moving when mobGriefing is false

When mobGriefing gamerule is false, silverfish won't even move, although will attack when on survival mode. Most likely caused by the fix of MC-80586.


Code analysis by @unknown:

The reason for this is the Silverfish first checks if mobGriefing is false, if so, the code returns false and the Silverfish cannot attempt to path find.

EntitySilverfish.java (MCP)

static class AIHideInStone extends EntityAIWander
    {
        public boolean shouldExecute()
        {
            if (!this.silverfish.worldObj.getGameRules().getBoolean("mobGriefing"))
            {
                return false;
            }
            else if (this.silverfish.getAttackTarget() != null)
            {
                return false;
            }
            else if (!this.silverfish.getNavigator().noPath())
            {
                return false;
            }
            else //...
        }
    }

Attachments

Comments 0

No comments.

Stuart Sterling Shoun

Agnes Larsson

Confirmed

Minecraft 16w35a, Minecraft 16w36a

Minecraft 16w40a

Retrieved