-
Bug
-
Resolution: Unresolved
-
None
-
1.19.4, 23w16a, 23w17a, 1.20 Pre-release 1
-
None
-
Confirmed
-
Collision, Performance
-
Normal
-
Platform
When an entity goes through a nether portal, it checks blocks in a large radius around the exit position for collisions and offsets trying to avoid suffocation. This process of collision checking cause variable amount of lag depending on how complex the collision model of the blocks around the portal are. Blocks with complex collisions (like cauldron, hopper, closed fence gates, composters, etc), cause way more lag than simple blocks (like stone, glass, etc).
This complex collision checking was introduced in 22w45a seemingly a fix for MC-80032.
Steps to reproduce:
- Make a 3x3 portal in overworld
- Go through this portal and extend the nether portal on the nether side to a 3x3 instead of a 2x3
- Place a repeating command block to kill the non player entities
- kill @e[type=!player,distance=..16]
- Make a 6x6x6 cube using cauldrons sandwiching the portal (See nether screenshot)
- Go back to overworld and place a repeating command block under the portal with
- summon ravager ~ ~2 ~
- Activate the this command block.
- Profile the lag.
- Repeat the same with simple collision block (stone or glass) or blocks with no collision (open fence gates)
Observeration:
- Complex collision blocks cause far more lag than simple blocks
- All this lag is caused by the collision resolution part of code which was introduced in 22w45a