Skip to content
This repository has been archived by the owner on Dec 31, 2024. It is now read-only.

Sodium compatibility issue #4

Open
Fefedu973 opened this issue Sep 21, 2022 · 37 comments · Fixed by #19 · May be fixed by #22
Open

Sodium compatibility issue #4

Fefedu973 opened this issue Sep 21, 2022 · 37 comments · Fixed by #19 · May be fixed by #22
Assignees

Comments

@Fefedu973
Copy link

No description provided.

@RaptaG
Copy link
Contributor

RaptaG commented Sep 21, 2022

1.18.2 and Fabric yes, for Sodium you should try and see.

@Fefedu973
Copy link
Author

Crash with sodium
Description: Initializing game

java.lang.RuntimeException: Mixin transformation of net.minecraft.class_761 failed
	at net.fabricmc.loader.impl.launch.knot.KnotClassDelegate.getPostMixinClassByteArray(KnotClassDelegate.java:418)
	at net.fabricmc.loader.impl.launch.knot.KnotClassDelegate.tryLoadClass(KnotClassDelegate.java:322)
	at net.fabricmc.loader.impl.launch.knot.KnotClassDelegate.loadClass(KnotClassDelegate.java:218)
	at net.fabricmc.loader.impl.launch.knot.KnotClassLoader.loadClass(KnotClassLoader.java:145)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:520)
	at net.minecraft.class_310.<init>(class_310.java:573)
	at net.minecraft.client.main.Main.main(Main.java:197)
	at net.fabricmc.loader.impl.game.minecraft.MinecraftGameProvider.launch(MinecraftGameProvider.java:460)
	at net.fabricmc.loader.impl.launch.knot.Knot.launch(Knot.java:74)
	at net.fabricmc.loader.impl.launch.knot.KnotClient.main(KnotClient.java:23)
Caused by: org.spongepowered.asm.mixin.transformer.throwables.MixinTransformerError: An unexpected critical error was encountered
	at org.spongepowered.asm.mixin.transformer.MixinProcessor.applyMixins(MixinProcessor.java:392)
	at org.spongepowered.asm.mixin.transformer.MixinTransformer.transformClass(MixinTransformer.java:234)
	at org.spongepowered.asm.mixin.transformer.MixinTransformer.transformClassBytes(MixinTransformer.java:202)
	at net.fabricmc.loader.impl.launch.knot.KnotClassDelegate.getPostMixinClassByteArray(KnotClassDelegate.java:413)
	... 9 more
Caused by: org.spongepowered.asm.mixin.throwables.MixinApplyError: Mixin [smooth-chunks.mixins.json:WorldRendererMixin from mod smooth-chunks] from phase [DEFAULT] in config [smooth-chunks.mixins.json] FAILED during APPLY
	at org.spongepowered.asm.mixin.transformer.MixinProcessor.handleMixinError(MixinProcessor.java:638)
	at org.spongepowered.asm.mixin.transformer.MixinProcessor.handleMixinApplyError(MixinProcessor.java:589)
	at org.spongepowered.asm.mixin.transformer.MixinProcessor.applyMixins(MixinProcessor.java:379)
	... 12 more
Caused by: org.spongepowered.asm.mixin.injection.throwables.InvalidInjectionException: @At("INVOKE") on net/minecraft/class_761::renderChunkBefore with priority 1000 cannot inject into net/minecraft/class_761::method_3251(Lnet/minecraft/class_1921;Lnet/minecraft/class_4587;DDDLnet/minecraft/class_1159;)V merged by me.jellysquid.mods.sodium.mixin.features.chunk_rendering.MixinWorldRenderer with priority 1000 [PREINJECT Applicator Phase -> smooth-chunks.mixins.json:WorldRendererMixin from mod smooth-chunks -> Prepare Injections ->  -> handler$dkg000$renderChunkBefore(Lnet/minecraft/class_1921;Lnet/minecraft/class_4587;DDDLnet/minecraft/class_1159;Lorg/spongepowered/asm/mixin/injection/callback/CallbackInfo;ZLit/unimi/dsi/fastutil/objects/ObjectListIterator;Lnet/minecraft/class_293;Lnet/minecraft/class_5944;Lnet/minecraft/class_284;ZLnet/minecraft/class_761$class_762;Lnet/minecraft/class_846$class_851;)V -> Prepare]
	at org.spongepowered.asm.mixin.injection.code.Injector.findTargetNodes(Injector.java:305)
	at org.spongepowered.asm.mixin.injection.code.Injector.find(Injector.java:240)
	at org.spongepowered.asm.mixin.injection.struct.InjectionInfo.prepare(InjectionInfo.java:421)
	at org.spongepowered.asm.mixin.transformer.MixinTargetContext.prepareInjections(MixinTargetContext.java:1338)
	at org.spongepowered.asm.mixin.transformer.MixinApplicatorStandard.prepareInjections(MixinApplicatorStandard.java:1043)
	at org.spongepowered.asm.mixin.transformer.MixinApplicatorStandard.applyMixin(MixinApplicatorStandard.java:393)
	at org.spongepowered.asm.mixin.transformer.MixinApplicatorStandard.apply(MixinApplicatorStandard.java:325)
	at org.spongepowered.asm.mixin.transformer.TargetClassContext.apply(TargetClassContext.java:421)
	at org.spongepowered.asm.mixin.transformer.TargetClassContext.applyMixins(TargetClassContext.java:403)
	at org.spongepowered.asm.mixin.transformer.MixinProcessor.applyMixins(MixinProcessor.java:363)
	... 12 more

@RaptaG
Copy link
Contributor

RaptaG commented Sep 21, 2022

Maybe rename this issue to: Sodium compatibility

@Fefedu973
Copy link
Author

Maybe rename this issue to: Sodium compatibility

I tested with my modpack (+200 mods) so I will retest with sodium and phosphorus only to be sure because it could be due to another mod

@RaptaG
Copy link
Contributor

RaptaG commented Sep 21, 2022

Try with Sodium and Smooth Chunks only then

@Fefedu973
Copy link
Author

Yes same issue not compatible

PLS add iris (sodium) compatiblity sodium is the new optifine even more with fabric. this is really crucial and it would be awesome thanks

@Fefedu973 Fefedu973 changed the title Is it 1.18.2 compatible? Fabric + sodium Sodium compatibility issue Sep 21, 2022
@RaptaG
Copy link
Contributor

RaptaG commented Sep 21, 2022

Sodium is not the new OptiFine, it lacks cosmetic features, but https://github.com/Fabulously-Optimized/fabulously-optimized is. (which includes it)

@TopchetoEU
Copy link
Owner

this is a planned feature, still i want to bring the mod to a more complete state before taking a look at sodium/iris support.

@Fefedu973
Copy link
Author

this is a planned feature, still i want to bring the mod to a more complete state before taking a look at sodium/iris support.

thank you very much I really hope that this compatibility will come one day

1 similar comment
@Fefedu973
Copy link
Author

this is a planned feature, still i want to bring the mod to a more complete state before taking a look at sodium/iris support.

thank you very much I really hope that this compatibility will come one day

@mads985
Copy link

mads985 commented Sep 21, 2022

Been waiting over a year now, jaw dropped when I saw this on Modrinth, really hope the Sodium compat can be worked out! This mod is great. - But I haven't been able to use it/alternatives since 1.13.2 D:

@TopchetoEU
Copy link
Owner

im going to try to work out sodium compatibility some time this week

@ghost
Copy link

ghost commented Sep 25, 2022

Hello, I'm really happy to see this mod for newer versions.
THANK YOU! Looking forward to the Sodium compatibility 🥰

@PinkGoosik
Copy link

sodium compat will be a banger

@EysseW
Copy link

EysseW commented Oct 3, 2022

Dang I like to see this thread.

@TopchetoEU
Copy link
Owner

im sorry, but life's being going on and i barely have free time. for now, i won't be able to work on this

@ghost
Copy link

ghost commented Oct 3, 2022

Take your time @TopchetoEU, the origin mod was last updated for 1.16 - we can wait 😊

@EysseW
Copy link

EysseW commented Oct 3, 2022

Is it very complicated? I am starting mod minecraft. Could I help with some easier parts?

@EysseW
Copy link

EysseW commented Oct 3, 2022

I do have to add, though, there is no pressure at all. We can absolutely wait. I'd just like to offer my help.

@TopchetoEU
Copy link
Owner

TopchetoEU commented Oct 10, 2022

I do have to add, though, there is no pressure at all. We can absolutely wait. I'd just like to offer my help.

If you'd like, try to adapt it to Sodium, just don't do anything stupid with the code. Also TBH, this is complicated, so if you're just starting out, I wouldn't make you go trough this

@RaptaG
Copy link
Contributor

RaptaG commented Oct 10, 2022

Any progress with this so far?

@EysseW
Copy link

EysseW commented Oct 10, 2022

Okay, I'm not going to try then. I'll only confused myself.

@RaptaG
Copy link
Contributor

RaptaG commented Oct 30, 2022

It's been a while.. Any progress?

@EysseW
Copy link

EysseW commented Nov 30, 2022

Greetings! It's been a while. How are you doing in this? Any progress?

@ghost
Copy link

ghost commented Dec 1, 2022

Hello @TopchetoEU, could a little donation for your awesome work, speed up the progress may? 😝
Greetings.

@TopchetoEU
Copy link
Owner

@mrniddala I don't really want donations, I just really don't know how to approach the problem. What I really need is someone who has experience with development for Sodium

@TopchetoEU
Copy link
Owner

hey everybody! sorry for keeping you waiting, but as of today, i've started the sodium compatibility development. it should be done by the end of the day, or tomorrow, idk.

@EysseW
Copy link

EysseW commented Jan 15, 2023

No worries! Good luck and have fun coding!

@TopchetoEU
Copy link
Owner

i'm trying to fix sodium support, but it seems as if sodium is at best incompatible with this mod. still, i'm going to try my best to port the functionality to sodium. thanks for waiting!

@TopchetoEU TopchetoEU linked a pull request Jan 15, 2023 that will close this issue
@TopchetoEU TopchetoEU reopened this Jan 15, 2023
@TopchetoEU
Copy link
Owner

TopchetoEU commented Jan 15, 2023

Sodium compatibility is impossible, because sodium seems to render whole regions at the same time (why does it do that is beyond me), and since chunk animations have to occur before each chunk animation call, sodium compatibility is impossible (almost). i could rewrite how sodium builds its chunks, but 1. this wouldn't be sodium compatibility, but sodium integration, 2. it would be unnecessarily hard for diminishing returns and 3. i could make sodium slower. so, sodium support is not planned. i'm aware that no sodium support is pretty much a deal-breaker for some of you (me included), but i can't do anything about it.

still, if you'd like to try to implement it yourself, go ahead, be my guest, make a PR.

thanks for supporting this mod!

@TopchetoEU TopchetoEU closed this as not planned Won't fix, can't repro, duplicate, stale Jan 15, 2023
@PinkGoosik
Copy link

Sodium users might look into chunks fade in as an alternative

@TopchetoEU
Copy link
Owner

TopchetoEU commented Jan 18, 2023

seems like a good alternative. for now, i'll just keep updating the mod. if i figure out a way to do chunk animations i'll be sure to update the mod

i'm sorry to let you down

@TopchetoEU TopchetoEU reopened this Jan 18, 2023
@TopchetoEU
Copy link
Owner

i will have one more shot at this issue, i'll keep you posted on the progress

@TopchetoEU TopchetoEU self-assigned this Jan 18, 2023
@EysseW
Copy link

EysseW commented Jan 18, 2023

I understand the difficulty. Thanks for the great mod, anyway!

@TopchetoEU
Copy link
Owner

so far, I've made almost no progress, since i'm currently making multiple projects with far higher priority than this. i hope that i can get back to this project, and get it to support sodium and iris, however, the developers of sodium have made sure that my life is as hard as possible

@TopchetoEU
Copy link
Owner

if anyone wants to give this a shot, i will leave a hint that using shaders is (i think) the way to go.

@TopchetoEU TopchetoEU linked a pull request Mar 27, 2023 that will close this issue
@Fefedu973
Copy link
Author

Check this mod that is the fork of the same mod as yours and have sodium support if you need help https://github.com/kerudion/chunksfadein

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
6 participants