Comment on Minecraft is removing code obfuscation in Java Edition
DaPorkchop_@lemmy.ml 19 hours agoThis doesn’t really change too much for the modding scene, it just allows the deobfuscation step to be skipped when setting up a dev environment. Mojang has already been providing official deobfuscation mappings for years, and before that we had community-made ones which were already pretty great.
There are already plenty of mods which drastically overhaul how major parts of the game work to get better performance, and there are some projects like Gregtech: New Horizons and CleanroomMC which have pretty much completely torn apart and rebuilt the game on older versions from before official deobfuscation mappings were even available.
Unattributed@feddit.online 13 hours ago
Right, but this means these efforts can be undertaken on the current release, and done without having to work around Mohjang’s obfuscation.
Removing this kind of barrier is a major change. Less time will be spent on trying to understand code that has been obscured from view. It will be easier to ensure “correctness” in code that is optimizing the server (ie, that new code will not break internal dependencies). It will be easier to ensure compatibility between the official release and community based extensions.
I understand that the modding community has been able to do a lot up to this point…(I play on an optimized modpack). But, I’m betting this will actually produce a larger jump in terms of the efficiency of all codebases - including Mohjangs. Just the reports that document issues (not CVE level issues) for Mohjang will lead to them improving the base code.
brucethemoose@lemmy.world 12 hours ago
It has. There have been major rewrites of parts of the codebase, like Sodium, Cubic Chunk, server frameworks, just to start.
The issue is that any major modification is inherently incompatible with other major modifications, hence most persist for one version (or a few) before the devs burns out maintaining it. There are two solutions to this:
Get Mojang to pull in the optimizations. Thus far, they have been uninterested in this (though some controversy over Optifine may have left a bad taste).
Pull the changes into a modding framework. Understandably, Fabric/Forge aren’t willing to pull in a huge overhaul they’d have to maintain.
Some modifications (like Sodium) minimize vanilla changes to prioritize compatibility, and are popular to the extent that some other mods implement workarounds. But this is rare, and it’s still problematic.
Unattributed@feddit.online 5 hours ago
I remember that. I think the issue there was it mostly handled badly… It seemed like Mojang was trying to go behind the communities back (which I thought sounded a lot like the way Microsoft does things…so I blamed them instead of Mojang). IMO - if this is an era of more open-collaboration it may be possible for Mojang to benefit from working with the community. (There is an excellent example of this in the way AMD has worked with the Open Source community…)
I can see that too… That’s why I am thinking that it might be possible for there to be a more collaborative effort… Like a repository set up where community devs can submit PR’s for changes, and Mojang can either approve or deny them. If that started working well, I could see a situation where there are specifically Mojang employed community devs, the role of working on changes that will help both the main Minecraft tree and the modding community.
(Okay, I am probably more optimistic than I should be – after all Microsoft is in the mix here…)
brucethemoose@lemmy.world 5 hours ago
Yeah, that sounds dreamy. It could certainly work.
And yeah, the problem is not just Microsoft but Mojang. Mojang is an extremely conservative/careful dev, even before they got bought by MS. It’s why the game hasn’t enshittified too bad, but also why development seems to move kinda slow for arguably the biggest game on Earth.
DaPorkchop_@lemmy.ml 12 hours ago
My point is that literally nobody has been looking at obfuscated code for at least 5 years by now. All the toolchains automatically handle de- and reobfuscation transparently to the point that nobody has to think about it anymore unless maybe you are one of the like 3 people who is actually maintaining the classloading stage of a modloader, or if you are manually writing a bytecode transformer (which almost nobody has needed to do for years either, ever since tools like Mixin entered the scene).
For 99.9% of the modding community, and this includes most optimization mods, the only thing that is going to change is everyone deletes a line or two from their
build.gradleand continues about their day.As far as reporting things to Mojang: again, nothing changes here either, everyone who has ever set up a mod dev environment already has a copy of the deobfuscated source code on their computer, which is the only thing they are looking at when inspecting the minecraft source code or making changes to it. There have been reports on the issue tracker with actual suggested code changes basically since the issue tracker became a thing.
Unattributed@feddit.online 5 hours ago
Okay - I am a bit of a dreamer, but I hope that Mojang dropping the obfuscation side of things is a sign that they are interested in working more closely with the community.
Of course, if I were to put on my pessimistic hat, I might think this is a move for Mojang to distance themselves from the Java edition as it’s likely that Microsoft thinks from a business perspective focusing on Bedrock is a better deal.