Mojira Archive
MC-115092

Squid/glow squid named "Dinnerbone" or "Grumm" is not upside-down

The bug

Squid named "Dinnerbone" or "Grumm" is not upside-down

How to reproduce

Use the following command to summon a squid named Dinnerbone:

/summon minecraft:squid ~ ~ ~ {CustomName:"{\"text\":\"Dinnerbone\"}",CustomNameVisible:1b,Silent:1b,NoAI:1b} 

Code analysis

Based on 1.12.2 MCP names.
In the method net.minecraft.client.renderer.entity.RenderSquid.applyRotations() where it applies the squid's model rotations, it does not have a check if the squid is named Dinnerbone or Grumm and to rotate if so. To fix this issue, this piece of code can be added at the end of the method applyRotations().

    String s = TextFormatting.getTextWithoutFormattingCodes(entityLiving.getName());

        if (s != null && ("Dinnerbone".equals(s) || "Grumm".equals(s)))
        {
            GlStateManager.translate(0.0F, entityLiving.height + 0.1F, 0.0F);
            GlStateManager.rotate(180.0F, 0.0F, 0.0F, 1.0F);
        }