Huge lighting updates lag the game.
The bug
This bug causes alot of light updates, dropping your FPS to 0 and most likely crashing your game.
This has been used for around a year now on several servers, this causes players to crash their game.
How to reproduce
- Create a new world (superflat, cheats on)
- Execute command: /fill ~20 ~200 ~-20 ~-20 ~200 ~20 stone
- Teleport yourself up to the platform. (/tp @a ~ ~205 ~)
- Place 2 observers facing into each other, make a hole 1 block away from the observer. (See screenshot for setup. the observers is to make a repeating redstone clock)
- Just place the piston so it pulls the block over the hole.
- Prepare yourself to see your FPS drop to 0.
Code analysis
The following is based on a decompiled version of Minecraft 1.12 using MCP940.
In the method net.minecraft.world.chunk.setBlockState() you have this~~
if (j >= i1) { this.relightBlock(i, j + 1, k); }
which relight blocks, but this is causing the massive FPS drops. What this does is, if j (posY) is bigger then i1, it will relight the block on the X, Y + 1, Z the player is.
If you remove the '+ 1' this issue will be fixed. idk why though.
if (j >= i1) { this.relightBlock(i, j, k); }
----------------------------------------------------------------------
When making a Creative world with bedrock at the bottom, air for most, and bedrock at the top, when you break the bedrock the game lags for about 7 seconds.
Example superflat preset: 3;minecraft:bedrock,250*minecraft:air,minecraft:bedrock;1;
I made a program that will take the "Something's taking too long!" messages and put it in a list. In the attached list, you can see that root.tick.level.connection is taking a VERY long time.
I hope this gets fixed soon, because it can be a huge exploit on servers.
^ original report
2013-03-11, 09:46 PM
2019-05-06, 02:22 PM
2018-10-23, 07:57 PM
48
26
fps, freeze, lag, light, lighting, lockup
Minecraft 1.4.7 - Minecraft 1.13.2
Minecraft 1.4.7, Snapshot 13w10b, Minecraft 1.5, Minecraft 1.8, Minecraft 1.8.1-pre2, Minecraft 1.8.1, Minecraft 1.8.2-pre4, Minecraft 1.8.8, Minecraft 15w44b, Minecraft 15w46a, Minecraft 1.8.9, Minecraft 15w51b, Minecraft 1.9.2, Minecraft 1.9.4, Minecraft 1.10.2, Minecraft 1.11.2, Minecraft 1.12 Pre-Release 6, Minecraft 1.12.1, Minecraft 1.12.2 Pre-Release 1, Minecraft 1.12.2, Minecraft 18w05a, Minecraft 18w09a, Minecraft 1.13, Minecraft 18w30b, Minecraft 1.13.1, Minecraft 1.13.2-pre1, Minecraft 1.13.2-pre2, Minecraft 1.13.2