AtomicStryker / atomicstrykers-minecraft-mods

Repository for my open source Minecraft Mods
https://atomicstryker.github.io/
180 stars 96 forks source link

large lag spikes on entering dimensional door dimension #483

Closed Moonyol closed 2 months ago

Moonyol commented 1 year ago

image

https://github.com/AtomicStryker/atomicstrykers-minecraft-mods/assets/92951072/da46caca-221d-4ffb-a2e8-e30dd7132a5d

AtomicStryker commented 1 year ago

No clue. You don't even have any light on you. Sorry, but i dont support such old versions anymore.

xJon commented 2 months ago

Just for reference, these are the results from a profiler: image

AtomicStryker commented 2 months ago

hackRenderGlobalConcurrently is a very expensive action that is meant to run one single time when you change dimensions. Clearly it's running again and again in your case.

But this is after the global disabler button check - so just use the turn off button while in that dimension.

AtomicStryker commented 2 months ago

If you want to tinker with this by yourself, do not let me stop you: https://github.com/AtomicStryker/atomicstrykers-minecraft-mods/tree/1.12.2/DynamicLights

If you are very lucky, "gradlew.bat build" will still work or require minimal googling and fixing. If you are unlucky, the relevant resources wont be online anymore.

The problem is most likely this line: https://github.com/AtomicStryker/atomicstrykers-minecraft-mods/blob/1.12.2/DynamicLights/src/main/java/atomicstryker/dynamiclights/client/DynamicLights.java#L193

Variable "world" will either be alternating between multiple dimensions or there will be something strange about it.

xJon commented 2 months ago

@AtomicStryker Thank you for the hint! Will further look into this.

xJon commented 2 months ago

Without any code changes, adding Dimensional Doors' dimension IDs to bannedDimensionIDs seems to be a valid workaround:

    I:bannedDimensionIDs <
        -1
        684
        685
        686
        687
        688
     >

Interestingly this is pre-populated with -1 for the Nether, I wonder why.

But the best solution appears to be adding Hesperus, which has code changes specifically for Dynamic Lights and it resolves this issue completely without requiring any configuration changes.

AtomicStryker commented 2 months ago

So a Bad interaction probably. Glad you resolved it for yourself

On Thu, 20 Jun 2024, 01:37 Jon, @.***> wrote:

Without any code changes, adding Dimensional Doors' dimension IDs to bannedDimensionIDs seems to be a valid workaround:

I:bannedDimensionIDs <
    -1
    684
    685
    686
    687
    688
 >

Interestingly this is pre-populated with -1 for the Nether, I wonder why.

But the best solution appears to be adding Hesperus https://www.curseforge.com/minecraft/mc-mods/hesperus, which resolves this issue completely without requiring any configuration changes.

— Reply to this email directly, view it on GitHub https://github.com/AtomicStryker/atomicstrykers-minecraft-mods/issues/483#issuecomment-2179575687, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAOFYBSGYFOZDBLFLQRELJDZIII2VAVCNFSM6AAAAABJR4UGZKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNZZGU3TKNRYG4 . You are receiving this because you were mentioned.Message ID: @.*** com>