[MC-11571] Huge lighting updates lag the game. Created: 11/Mar/13 Updated: 06/May/19 Resolved: 23/Oct/18 |
|
| Status: | Resolved |
| Project: | Minecraft: Java Edition |
| Component/s: | None |
| Affects Version/s: | 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 |
| Fix Version/s: | Minecraft 18w43a |
| Type: | Bug | ||
| Reporter: | Oval | Assignee: | [Mojang] Georgii Gavrichev |
| Resolution: | Fixed | Votes: | 48 |
| Labels: | fps, freeze, lag, light, lighting, lockup | ||
| Attachments: |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Issue Links: |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| CHK: | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Confirmation Status: | Confirmed | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Game Mode: | Survival | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Description |
|
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
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
|
| Comments |
| Comment by RedCMD [ 11/Sep/18 ] |
|
If the stone platform is at y=200 X=29 (Distance of Light spread from center) Y=200 (Height of platform) X=15 (Sky Light level) Y=200 (Height of platform)
Oh and redstone dust does NOT produce light updates (they cause block updates) |
| Comment by Oval [ 11/Sep/18 ] |
|
RedCMD It literally doesn't matter. you still drop frames on Y: 200 |
| Comment by RedCMD [ 11/Sep/18 ] |
|
change "fill ~20 ~200 ~-20 ~-20 ~200 ~20" to "/fill ~20 240 ~-20 ~-20 240 ~20" and "/tp @a ~ ~205 ~" to "/tp @p ~ 250 ~" |
| Comment by Saisho Bready [ 28/Jul/18 ] |
|
confirmed for breaking last bedrock level on 18w30b |
| Comment by DecafDawren [ 13/Feb/18 ] |
|
This also occurs on Java 8 and on Linux. |
| Comment by LuxiKeks [ 04/Feb/18 ] |
|
This is affecting every 1.13 snapshot as well. |
| Comment by Daniil Aripov [ 19/Sep/17 ] |
|
From all comments I noticed this is both client-side and server-side issue. When removing light source at underground, it would lag more than if you remove it at surface during daytime. More checks needed about light updates client-side and server-side. |
| Comment by McModknower [ 13/Sep/17 ] |
|
Still in 1.12.2 Pre-release. Please fix this Mojang. |
| Comment by Midnaait [ 31/May/17 ] |
|
Still happening in the 1.12 pre-release 6 |
| Comment by Sven [ 19/Apr/16 ] |
|
Well you can add 1.9.2 to the list and I don't really think this is a creative only issue either... I noticed lagspikes when building the roof and the last block just kills it completely (client and server both on quite some hardware)... |
| Comment by Alun Blue [ 04/Jan/16 ] |
|
The way I came across this bug was when changing a large 1 block tall plane of grass blocks. Since there was no light underneath the platform, it would lag when removing the light from underneath the platform when the hole creating the light (from the sky) was filled in. This only happened when the light went away. For me it specifically caused a 2 - 3 second lag in root.tick.keyboard |
| Comment by PlNG [ 19/Dec/15 ] |
|
"Simple" build that confirms the issue. These spike to 50% for me: |
| Comment by user-f2760 (Inactive) [ 03/Nov/15 ] |
|
confirmed for 15w44b |
| Comment by [Mod] Sonicwave [ 18/Jan/15 ] |
|
Confirmed in 1.8.2-pre4. The lag seems much more extreme when blocking the light than when removing the block. |
| Comment by Bentroen [ 16/Dec/14 ] |
|
Confirmed for 1.8.1. As a prove that this is related to lighting, if you cover yourself in a 1x2x1 hole with no light (or any room with a low light level), open a hole to the void, and then cover it, it will not lag, because of the low light level. But if you don't block the light, it will lag a lot. |
| Comment by KingSupernova [ 08/Dec/14 ] |
|
I noticed that this only happens with opaque blocks, implying that it is a lighting issue. Also, if the hole you are filling in is filled with water, it won't lag. By the way, a much easier way to test this is to just make a one layer thick superflat world. |
| Comment by [Mod] Sonicwave [ 21/Oct/14 ] |
|
Confirmed for 1.8.1-pre2. |
| Comment by [Mod] Sonicwave [ 10/Oct/14 ] |
|
Are the affected versions still getting updated? ( |
| Comment by ggxl [ 28/Jun/14 ] |
|
I've heard that this can be problematic for complicated, exposed redstone mechanisms (because lighting updates need to occur whenever dust and such turns on/off). |
| Comment by StrangeOne101 [ 21/Apr/14 ] |
|
I can reproduce this in the latest 14w11b snapshot. Causes lag that lasts just under half a second. Way to reproduce: 1. Create a new world and dig down with a 1x1 tunnel to bedrock level. |
| Comment by fienxjox [ 22/Mar/14 ] |
|
Cannot reproduce in 14w11b. World preset used:
The used:
to cause as many lighting updates as possible. Smooth lighting at maximum, render distance 16. |
| Comment by Kumasasa [ 11/Mar/13 ] |
|
Confirmed. 2013-03-11 22:57:56 [SERVER] [WARNING] Can't keep up! Did the system time change, or is the server overloaded? 2013-03-11 22:58:12 [SERVER] [WARNING] Can't keep up! Did the system time change, or is the server overloaded? 2013-03-11 22:59:20 [SERVER] [WARNING] Can't keep up! Did the system time change, or is the server overloaded? 2013-03-11 23:00:06 [SERVER] [WARNING] Can't keep up! Did the system time change, or is the server overloaded? 2013-03-11 23:00:11 [SERVER] [INFO] Saving and pausing game... in the console. |
| Comment by Dwayne Slater [ 11/Mar/13 ] |
|
I don't think I broke the redstone, so it may still be running. |
| Comment by Kumasasa [ 11/Mar/13 ] |
|
Yes, please upload the world. |
| Comment by Dwayne Slater [ 11/Mar/13 ] |
|
In vanilla, I made a piston that would extend and rectract on an uncovered block. The lag was horrendous. I got down to 0 fps before the F3+C worked. I can upload the world if you want me to. |
| Comment by Kumasasa [ 11/Mar/13 ] |
|
Please force a crash by pressing F3 + C for 10 seconds while ingame and attach the crash report here. |
| Comment by Dwayne Slater [ 11/Mar/13 ] |
|
Also, root.tick.keyboard lags when you break the block. |