Command blocks running commands for a lot of entities, or having a lot of command blocks producing some output will very quickly start lagging out the client or server. This seems to stem from the large amounts of log messages produced from the command blocks and does not happen with the commandBlockOutput gamerule disabled.
It seems that this issue is more likely to occur on computers with lower configurations. If your computer is as good as my new one, you might need to throw several snowballs to reproduce the problem.
Example steps to Reproduce:
1. Position a loop command block and configure it to be always active.
2. Input the first command: execute at @e[type=minecraft:snowball] run summon minecraft:item_display ~ ~ ~ {item:{id:'minecraft:diamond'},item_display:{gui:true}}
This is used as a simple way to increase the load/log spam from the next command block in a controlled way
3. Place another loop command block and similarly configure it for perpetual activation.
4. Enter the second command: execute as @e[type=minecraft:item_display] at @s run tp @s ~ ~ ~ facing entity %YOUR_NAME%
Remember to substitute `%YOUR_NAME%` with your actual Minecraft username.
5. Throw a snowball.
(If your computer is as good as my new one, you might need to throw several snowballs to reproduce the problem.)
6. Observe the immediate freezing of the game.
Attachments
Comments 5
It seems that this issue only occurs when the command block output game rules are enabled, so the reason why item display entities are more laggy should be because their names are relatively longer than other entities. Mojang should modify the output performance of the command block.
Thanks for confirming, I updated the report to focus more in the logging part than the teleportation
Thank you for your report!
After consideration, the issue is being closed as Invalid.
This report does not describe a bug.
Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support (Technical Issues) – 📧 Microsoft Support (Account Issues)
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki
The teleporting itself doesn't seem to cause issues on my end, but the logging alone might play an important factor here, though this can depend a lot on the OS/system.
Do you have the commandBlockOutput gamerule enabled or disabled? Please make sure to test with the output disabled.