Alfheim Lighting Engine

Alfheim Lighting Engine

715k Downloads

Alfheim WARN: `Requious Fracto` compat

Krutoy242 opened this issue ยท 4 comments

commented

Describe the bug

When Requious Fracto machines emit particles during work, debug.log spammed with this mesage:

[Client thread/WARN] [Alfheim]: Something (likely another mod) has attempted to modify the world's state from the wrong thread!
This is *bad practice* and can cause severe issues in your game.
Alfheim has done as best as it can to mitigate this violation, but it may negatively impact performance or introduce stalls.
In a future release, this violation may result in a hard crash instead of the current soft warning.
You should report this issue to our issue tracker with the following stacktrace information.
java.lang.IllegalAccessException: World is owned by 'Server thread' (ID: 305), but was accessed from thread 'Client thread' (ID: 1)
	at dev.redstudio.alfheim.lighting.LightingEngine.lock(LightingEngine.java:206) [LightingEngine.class:?]
	at dev.redstudio.alfheim.lighting.LightingEngine.processLightUpdatesForType(LightingEngine.java:180) [LightingEngine.class:?]
	at net.minecraft.world.chunk.Chunk.getLightFor(Chunk.java:2795) [axw.class:?]
	at net.minecraft.world.World.getLightFor(World.java:859) [amu.class:?]
	at net.minecraft.world.World.alfheim$getLight(World.java:5661) [amu.class:?]
	at net.minecraft.block.Block.alfheim$getLightFor(Block.java:2766) [aow.class:?]
	at net.minecraft.block.state.BlockStateContainer$StateImplementation.alfheim$getLightFor(BlockStateContainer.java:625) [awu$a.class:?]
	at net.minecraft.world.World.getLightFromNeighborsFor(World.java:5651) [amu.class:?]
	at net.minecraft.world.World.getCombinedLight(World.java:888) [amu.class:?]
	at net.minecraft.client.particle.Particle.getBrightnessForRender(Particle.java:344) [btf.class:?]
	at requious.particle.ParticleSmokeColored.getBrightnessForRender(ParticleSmokeColored.java:23) [ParticleSmokeColored.class:?]
	at net.minecraft.client.particle.Particle.renderParticle(Particle.java:189) [btf.class:?]
	at net.minecraft.client.particle.ParticleSmokeNormal.renderParticle(SourceFile:42) [btm.class:?]
	at net.minecraft.client.particle.ParticleManager.redirect$zzk000$particleculling$maybeCullParticle(ParticleManager.java:576) [btg.class:?]
	at net.minecraft.client.particle.ParticleManager.renderParticles(ParticleManager.java:325) [btg.class:?]
	at net.minecraft.client.renderer.EntityRenderer.renderWorldPass(EntityRenderer.java:1387) [buq.class:?]
	at net.minecraft.client.renderer.EntityRenderer.renderWorld(EntityRenderer.java:1259) [buq.class:?]
	at net.minecraft.client.renderer.EntityRenderer.updateCameraAndRender(EntityRenderer.java:1062) [buq.class:?]
	at net.minecraft.client.Minecraft.runGameLoop(MinecraftAccessor.java:1097) [bib.class:?]
	at net.minecraft.client.Minecraft.run(MinecraftAccessor.java:7592) [bib.class:?]
	at net.minecraft.client.main.Main.main(SourceFile:123) [Main.class:?]
	at jdk.internal.reflect.DirectMethodHandleAccessor.invoke(Unknown Source) ~[?:?]
	at java.lang.reflect.Method.invoke(Unknown Source) ~[?:?]
	at top.outlands.foundation.LaunchHandler.launch(LaunchHandler.java:119) [LaunchHandler.class:?]
	at jdk.internal.reflect.DirectMethodHandleAccessor.invoke(Unknown Source) ~[?:?]
	at java.lang.reflect.Method.invoke(Unknown Source) ~[?:?]
	at top.outlands.foundation.boot.Foundation.main(Foundation.java:41) [foundation-0.13.2.jar:?]
	at org.prismlauncher.launcher.impl.StandardLauncher.launch(StandardLauncher.java:87) [NewLaunch.jar:?]
	at org.prismlauncher.EntryPoint.listen(EntryPoint.java:129) [NewLaunch.jar:?]
	at org.prismlauncher.EntryPoint.main(EntryPoint.java:70) [NewLaunch.jar:?]

And not, I'm not reproduced this issue with as few other mods as possible installed since this would know if this issue actually require this kind of setup. Please write if needed.

Reproducibility

  • I reproduced this issue with as few other mods as possible installed.
  • I am unable to reproduce this issue consistently.

Screenshots and/or videos

No response

Logs

https://mclo.gs/HNAWEi5

Debug Logs

No response

Crash Reports

No response

Alfheim Version

1.3

Forge Version

14.23.5.2860

MixinBooter Version

CleanroomMMC

Java Version

22

Java Virtual Machine

Hotspot

Operating System

Windows 10

GPU Vendor

NVIDIA

Code of Conduct

  • I agree to follow this project's Code of Conduct
commented

Looks like a similar issue to #48, Requious Frakto uses proxy methods to spawn particles, which can leak the server's world (in singleplayer) if sides are not checked beforehand. It looks like the earliest the side should be checked and only run on client is here.
Should I address this issue (and maybe the Tinkers one) in a Universal Tweaks PR? Or do you plan on fixing @Desoroxxx?

commented

Should I address this issue (and maybe the Tinkers one) in a Universal Tweaks PR?

Yeah I don't think I can do anything on my side to fix the issue.

Or do you plan on fixing @Desoroxxx?

What I plan on fixing is the log, as I think it should say to report to original mods author not me lol

commented

Makes sense, I'll make a PR to Universal Tweaks for the fixes/workarounds. You might want to add in the message to report to Universal Tweaks as well considering most mods probably are no longer maintained.

commented

I removed the sentence about reporting entirely