Mojira Archive
MC-144427

Bad performance of targetSelector of agressive mob AI

The bug

On my server, I must set doMobSpawning to false because AI of aggressive mob take all resources!
If I add datapack to remove AI on zombie, that's skeleton AI which take all resources.
And if I add datapack to remove AI on skeleton too, that's creeper AI which take all resources, etc.

[06] |   |   |   |   |   |   tick - 99.34%/91.47%
[07] |   |   |   |   |   |   |   minecraft:zombie - 89.92%/82.25%
[08] |   |   |   |   |   |   |   |   ai - 98.83%/81.29%
[09] |   |   |   |   |   |   |   |   |   newAi - 99.97%/81.27%
[10] |   |   |   |   |   |   |   |   |   |   targetSelector - 98.83%/80.32%
[11] |   |   |   |   |   |   |   |   |   |   |   goalSetup - 99.96%/80.29%
[12] |   |   |   |   |   |   |   |   |   |   |   |   canSee - 99.81%/80.14%
[12] |   |   |   |   |   |   |   |   |   |   |   |   unspecified - 0.19%/0.15%
[11] |   |   |   |   |   |   |   |   |   |   |   unspecified - 0.04%/0.03%
[11] |   |   |   |   |   |   |   |   |   |   |   goalTick - 0.00%/0.00%
...

With two players that's ok. But with four that start to lag, and with 10 players, the server crashes because tick too long with max-tick-time to 60 secondes (max-tick-time=60000).

Cannot Reproduce

Desjardins Jérôme

2019-02-19, 10:08 PM

2024-11-14, 01:09 PM

2024-11-14, 01:09 PM

20

11

Community Consensus

Important

Platform

Performance

Minecraft 19w05a - 21w19aMinecraft 19w05a, Minecraft 19w06a, Minecraft 19w07a, 1.16.2, 21w08b, 21w19a

-