mojira.dev
MC-107171

maxEntityCramming is off-by-one

Setting it to 2 allows 3 mobs in one spot. They will suffocate when there are 4 mobs in one spot.
As Jeb_ mentioned, one entity more than gamerule should suffocate mobs:
For 1.11 there is a new game rule called "maxEntityCramming" with the default set to 24 (i.e. 25+ entities at the same spot will suffocate)
but they suffocate when there are 2 more mobs.
This behaviour disallows setting this gamerule to "when anything touches anything, suffocate them" by giving value of 1.

Comments 5

Suggested - works as intended. maxEntityCramming tells with how many other mobs a mob can collide, so the value of 24 means one mob can collide with other 24, so there can be 25 in one spot.

Read the ticket, first line:

Setting it to 2 allows 3 mobs in one spot. They will suffocate when there are 4 mobs in one spot.

So a value of 24 allows 25 without suffocation, nr 26 starts to suffocate.

@unknown Also, read last line:

This behaviour disallows setting this gamerule to "when anything touches anything, suffocate them" by giving value of 1.

As mapmaker, if you want to make use of it without having to set up a CB-apparatus for it, this would mean that "works as intended" as you suggest (of course absolutely unselfishly) is not an option, as it would allow 2 mobs at one spot, if set to "1", like the OP wrote.

If we have to have this gamerule per default now in 1.11 (which I absolutely object by the way, it should be off by default from my perspective), then at the very least I want to have it accurate so it's at the very least usable for mapmakers.

Confirmed in 16w39c

Confirmed in 16w40a

Irbis

Jens Bergensten

Confirmed

Minecraft 16w38a, Minecraft 16w39a, Minecraft 16w39b, Minecraft 16w39c, Minecraft 16w40a

Minecraft 16w41a

Retrieved