Live data from Hacker News

Minecraft removing obfuscation in Java Edition

minecraft.net

451–460 of 478 posts

Re: Minecraft removing obfuscation in Java Edition

#451
post #137

Earlier quoted context omitted.

First time I have heard of object-oriented obfuscation. I get it, but in general I don't get the OO hate. It's all about the problem domain imo. I can't imagine building something like a graphics framework without some subtyping. Unfortunately, people often use crap examples for OO. The worst is probably employee, where employee and contractor are subtypes of worker, or some other chicanery like that. Of course in th…

For me, it's the fact that the mess of DAOs and Factories that constituted "enterprise" Java in the 00s was a special kind of hellscape that was actively encouraged by the design of the language. Most code bases don't need dynamically loaded objects designed with interfaces that can be swapped out. In fact, that functionality is nearly never useful. But that's how most people wrote Java code. It was terrible and taug…

I think the best description of this kind of "obfuscation" that especially afflicted Java still is Steve Yegge's "Kingdom of Nouns" rant:

https://steve-yegge.blogspot.com/2006/03/execution-in-kingdo...

Re: Minecraft removing obfuscation in Java Edition

#452

Earlier quoted context omitted.

Java was probably close to 50% of the job market at some point in the 2000s and C significantly dried up with C++ taking its place. So I'm afraid everyone was right actually. To be honest, I'm convinced the reason so many people dislike Java is because they have had to use it in a professional context only. It's not really a hobbyist language.

Just for the record, I don't think C ever dried up in the embedded space. And the embedded space is waaaay bigger than most people realise, because almost all of it is proprietary, so very little "leaks" onto the public interwebs.

Believe it or not but there is plenty of Java and C++ in the embedded space. It’s far from being a C fortress.

Re: Minecraft removing obfuscation in Java Edition

#453

There is always one thing that I found so facintating with the modding scene in Minecraft. Because Minecraft does not have a modding api but the java byte code can be changed. People simply developed their own way of creating an API. There are 2 main modding APIs. Forge/Neo-Forge and Fabric. [1]Fabric uses Mix-ins while [2]Forge uses a more event based system that is added to the source code of minecraft where they a…

It won't do much though. Although it will make things a bit easier. A lot of minecraft mod requires direct modification to Minecraft's core mechanism. For example in popular mods: create, immersive portal and distant horizon all taps in minecraft's collision mechanism or rendering pipeline in a quite aggressive way that unlikely there will ever an abstraction be able to handle that.

And, no. Although forge does not encourage you to use it. It also supports mixin like direct modification. It's just less polished than mixin(requires more knowledge to java Bytecode)

It's unrealistic to ask mojang to make an abstraction that you can actually change everything in the core without direct modification (let alone how do mojang know what part need to be abstracted?)

Re: Minecraft removing obfuscation in Java Edition

#454
post #225

Earlier quoted context omitted.

> I think the OO hatred comes from how academia and certain enterprise organisations for our industry picked it up and taught it like a religion. This, this, this. So much this. Back when I was in uni, Sun had donated basically an entire lab of those computers terminals that you used to sign in to with a smart card (I forgot the name). In exchange, the uni agreed to teach all classes related to programming in Java, a…

Probably the Sun Ray computer. https://en.wikipedia.org/wiki/Sun_Ray

This was it!

Re: Minecraft removing obfuscation in Java Edition

#455
post #444

Earlier quoted context omitted.

> There is nothing on the modules as programming concept that requires the existence of functions as entity. I didn't claim it does. To make the point though: bare functions are a much simpler building block, and a much cleaner building block than classes. Classes by their nature put state and behavior in one place. If one doesn't need that, then a class is actually not the right concept to go for (assuming one has t…

From type systems theory point of view, a class is an extensible module that can be used as a variable. As mentioned in another reply, Java did not invent this, it was building upon Smalltalk and SELF, with a little bit of Objective-C on the side, and C++ like syntax. Try to create a single function in Smalltalk, or SELF. http://stephane.ducasse.free.fr/FreeBooks.html https://www.strongtalk.org/ https://selflanguage.…

> The code browser in Eclipse

> https://i.sstatic.net/4OFEM.png

«

Error 1011 Ray ID: 9973d6cc1badc66a • 2025-10-31 14:28:28 UTC

Access denied

What happened?

The owner of this website (i.sstatic.net) does not allow hotlinking to that resource (/4OFEM.png).

»

Re: Minecraft removing obfuscation in Java Edition

#456
post #180

Earlier quoted context omitted.

In 2004 I played an MMO game on a pirated server. The owner of the server somehow got a version of the server binary, and used a hex editor (!) to add new features to the binary over time. It's the closest I've ever see to someone literally being one of the hackers from Matrix, literally staring at hexadecimal and changing chars one at a time

Wasn't that WoW? I vaguely recall that a lot of the private servers worked off of a copied and / or decompiled version of their own server software for years, which is also why they never went further than the WotLK expansion. (the other part of that was people didn't want to, but that's another discussion)

AFAIK the WoW server code was never leaked. All private server code bases were developed by reverse engineering network traffic, game behaviour and client asset files.

E.g. the code for AzerothCore is fully available (and very easy to run on very low spec hardware)

https://github.com/azerothcore/azerothcore-wotlk

Re: Minecraft removing obfuscation in Java Edition

#457
post #254

Earlier quoted context omitted.

I've always wanted my editor's go-to functionality to take me to an abstract class instead of the place where the actual logic resides. Good times.

Any modern IDE will let you immediately bring up the subclasses with a single hotkey. If you have an abstract class with only a single subclass and that's not because new code is going to be added soon then yes, it's a bad design decision. Fortunately, also easy to fix with good IDEs.

In my last project every class had a corresponding abstract class, and then we used DI to use the real class. Good to be rid of it.

Re: Minecraft removing obfuscation in Java Edition

#458

Earlier quoted context omitted.

For me, it's the fact that the mess of DAOs and Factories that constituted "enterprise" Java in the 00s was a special kind of hellscape that was actively encouraged by the design of the language. Most code bases don't need dynamically loaded objects designed with interfaces that can be swapped out. In fact, that functionality is nearly never useful. But that's how most people wrote Java code. It was terrible and taug…

> Most code bases don't need dynamically loaded objects designed with interfaces that can be swapped out. In fact, that functionality is nearly never useful. But that's how most people wrote Java code. Perhaps I'm not following, but dynamically loaded objects are the core feature of shared libraries. Among it's purposes, it allows code to be reused and even updated without having to recompile the project. That's pret…

> Also, interfaces are extremely important to allow your components to be easily replaced even at runtime.

The share of all software that actually benefits from this is extremely small. Most web-style software with stateless request/response is better architected for containers and rolling deployments. Most businesses are also completely fine with a few minutes of downtime here and there. For runtime-replacement to be valuable, you need both statefulness and high SLA (99.999+%) requirements.

To be fair, there is indeed a subset of software that is both stateful and with high SLA requirements, where these techniques are useful, so it's good to know about them for those rare cases. There is some pretty compelling software underneath those Java EE servers for the few use-cases that really need them.

But those use-cases are rare.

Re: Minecraft removing obfuscation in Java Edition

#459
post #446

Earlier quoted context omitted.

When you're engaging in game design, you usually want to make a coherent sandbox. If the best way to produce electricity in your electricity mod is to enslave an army of witches to throw healing potions at each other, it's probably not your design intention. You probably wanted it to involve digging for coal, or solar panels. In current Minecraft a lot of resources are renewable via villager trading. The best way to…

Or maybe they just wanted to mix fantasy and tech? Or maybe it wasn't intentional, but emergent... sort of like, you know, playing in a sandbox? Villager trading is another new(ish) mechanic I don't partake in. I know others who don't either. I don't think we're playing the game wrong. And if a mod/pack developer doesn't want players to use vanilla mechanics, they can disable those, as many, many developers do.

It's not that simple in practice.

Re: Minecraft removing obfuscation in Java Edition

#460
post #446

Earlier quoted context omitted.

Or maybe they just wanted to mix fantasy and tech? Or maybe it wasn't intentional, but emergent... sort of like, you know, playing in a sandbox? Villager trading is another new(ish) mechanic I don't partake in. I know others who don't either. I don't think we're playing the game wrong. And if a mod/pack developer doesn't want players to use vanilla mechanics, they can disable those, as many, many developers do.

It's not that simple in practice.

What isn't? Disabling Vanilla mechanics? Specifically which of those you mentioned aren't easily disabled with a data pack or simple mod?
Post reply on HN