48 comments

[ 0.28 ms ] story [ 91.6 ms ] thread
Similar projects:

* DevilutionX: decompiled and modern version of Diablo for the PC - https://github.com/diasurgical/devilutionX

* pokered: decompiled version of Pokemon Red for the Gamboy - https://github.com/pret/pokered

* zelda1: decompiled version of Zelda for the NES - https://github.com/aldonunez/zelda1-disassembly

* supermetroid: decompiled version of Super Metroid for the SNES - https://github.com/strager/supermetroid

* VAC: decompiled version of Valve Anti Cheat (VAC) for PC - https://github.com/danielkrupinski/VAC

Nerrel just finished his multi-year effort of making an extremely high quality (as in effort and faithfulness not just high quality bitmaps) texture pack last month as well https://youtu.be/ovknYMdIP9I. I'm willing to bet we'll see quite the combination of enhancements by fans in time, much like happened with SM64.
Regarding the SM64 decompilation, a nice showcase of the modifications that have been created based on that work can be seen on the YouTube entertainer SimpleFlips' channel: https://youtube.com/playlist?list=PL3Hg1a3VjI1bfcErqawMUWhB6...

He also maintains a website where you can download and review many of them: https://romhacking.com/

Couldn't find it but, did they fix that one ghost coin in little-tall island?
I assume not, since that would require an asset change, and the game assets are not included with the decompilation project. It's also not a goal of the project to change existing behaviors of the game (including bugs)
The vast majority of what's showcased on that site and playlist were done via assembly hacks, not c.

Super Mario 64 decomp has only publicly been available since late 2019. And even then, there's still holdouts as the toolset for ye olde ways has been around longer.

Oh no it's a public GitHub. Nintendo will throw their lawyers at this. Download while you can.
"The kind of reverse engineering ZRET do is made legal because the fans involved did not use any leaked content. Instead, they painstakingly recreated the game from scratch using modern coding languages. The project also does not use any of Nintendo’s original copyrighted assets such as graphics or sound."
The authors of re3/revc thought the same and now they're going to court
re3/revc is going to court largely because they included assets in their repository and advertised derivative works/ports. zret purposefully avoided all of these points making this oot mq decomp.

Of course Nintendo can submit a case if they like but it'd be a lot less likely to enter an actual trial like re3/revc. A better comparison would be https://github.com/n64decomp/sm64 which followed the exact same guidelines as this project. Nintendo chased after and DMCA'd many projects based on it but never the original project.

Just saying that doesn't make it true through. If they ran the source code through a decompiler and then cleaned up the output, they're not using any leaked content but it's still potentially infringing on Nintendo's copyrighted source code. That's why some projects choose to make "clean room implementations".
Legal or not also has only tenuous correlation to github taking action.
It doesn't matter if you use original assets or not. Duplicating the heart of a work, in any way, is copyright infringement. Even streaming a video game, against the wishes of the copyright holders, is copyright infringement. Recording of playing a video game is not your own work.

U.S. copyright law is absolutely gross, we are used to these companies choosing to not enforce infringement and targeting specific people/projects.

It's legal and should be legal. You purchased the game, it is yours to do with what you want including converting the machine code into C.

Decompiling Adobe cloud is illegal because you are just renting a seat to use it. It's not yours.

This modern garbage of paying 70k for a car that isn't really yours needs to stop and people need to stop paying a purchase price for something they are just "renting".

In the U.S. that is not accurate. Any form of breaking DRM, under the DMCA, is infringement. Even cracking DVD is infringement. Even if the product had a fixed key of 1234.

Even if it were legal with your single product, releasing it to the wider web would be illigal. Same as distributing digital copies is. Again, U.S. copyright law is designed heavily against individual owners. It is designed for big corporations to own anything forever. Research how Disney has changed copyright limits if you don't believe me. Look up copyright cases on YouTube.

> The kind of reverse engineering ZRET do is made legal because the fans involved did not use any leaked content.

IANAL, but - there's no way that can be true. Reverse engineering of machine code is generally forbidden except for very specific exemptions, like compatibility with other systems. Furthermore, even under such exemptions, you are still generally not allowed to share the results.

Even putting reverse engineering aside, they are still distributing code that was written by Nintendo (although meticulously transformed in a way that makes reading and modification much easier), and which still belongs to them.

What would have been legal is if either this was a black box reverse engineering effort, in which all code was written without ever looking at the original machine code, or releasing a tool which fully automatically decompiles the ROM (which is not included with the tool, and must be acquired separately, probably from dumping a cartridge).

(Had to research this subject a bit as part of my collaboration on https://github.com/Davidebyzero/Snipes)

IANAL either but it really depends on your jurisdiction. There are many places outside North America where it is quite legal to RE without a black box.
Yeah this article is very unclear. It talks about decompiling from existing code (namely the GameCube master quest version) but also recreating the game from scratch. Which is it?
probably both. singular approaches rarely work for everything when reverse engineering.
Wow, that's a really quaint acronym. Kudos.
> Reverse engineering of machine code is generally forbidden except for very specific exemptions, like compatibility with other systems

Reverse engineering is generally legal in the US, except in cases where a EULA expressly forbids it. Since n64 titles are not covered by EULAs, to the best of my knowledge, reverse engineering them is perfectly legal. Distribution of such results however may not be.

Good to know. Perhaps the US law makes more sense here, because banning reverse engineering by itself is not really enforceable.

For Europe there is the EU Directive 2009/24/EC, and I think I remember reading something almost like that predating it by many years in some country's (possibly mine) legislation.

Legality requires to be tested in court. Until it is, anything is technically neither legal nor illegal unless you opt to not contest it in court when exerted by other parties.
it can probably be argued that the effort put in by people surpasses the requirement for derivative work, and it should go without saying that without the ROM (or other source of assets such as sounds, art, and music) that the code in question compiles into something that doesn't function.

this isn't the result of a single tool doing the work, but a lot of tools and a lot of people looking at the output of those tools and interpreting that output, then changing it to make sense within the scope of the project framework(s).

probably very similar to an emulator for a single game.

I am also not a lawyer.

Which also makes me wonder, if it's not legal anyway... was the Ocarina of Time source not included in the major Nintendo leak from last year? A lot of other stuff from that era certainly was...
No, the source code was not leaked. Only a bunch of assets.
Just as an FYI to casual readers, I'd take the above post with a large dose of skepticism. If I'd wager a guess, the research in question was performed during Google v. Oracle winding it's way through the courts, because for a period there was concern that Sony v. Connectix and the other leading cases in the area were about to be tossed aside, which ultimately didn't happen.
Was the code written by Nintendo? They wrote c code that compiles into the Zelda game but if we were to look at Nintendo's source I can guarantee it's different than what this team produced.
it’s in C, not machine code?
On a related note, it’s a shame that you have to look to emulators to play this game because Nintendo’s official emulation is so bad.
Original hardware + an everdrive + some hardware upscaler [1] is the way to do it.

[1] Super64 is excellent - its "blurry" mode makes things look authentic on my HDTV.

For lowest latency you may also need a CRT. Thin screens are getting better but every stage of the pipeline can introduce more lag than the original.
That's true. I have a trove of CRTs for playing Melee :)

But for the average N64 classic, a commercial HDTV with an upscaler works fine. A high refresh rate monitor also works great (even for something as precise as Melee.)

OT, but it's bizarre that they call it "Zelda 64" in the title
I bet the author glanced at their site named "Zelda 64" and assumed that's how they referred to OOT not realizing they have other projects (some not even on the N64 now) as well.
Ah I didn't notice the source website. That makes a little more sense (on the reporting side at least). I wonder if the fan site is named that way to avoid trademark issues with the full name?
It might be to evoke nostalgia for when it was still in development and the press was hyping it up under that name. Even Nintendo used it occasionally (including for a preview feature in Nintendo Power).
zelda64.com was also the official website when Ocarina of Time came out, presumably because, at the time, the zelda.com domain was already taken by a porn site. That was an interesting discovery for 10-year-old me.
There are teams working on both the OoT decomp and a MM decomp, so I think that combining both of those under the Zelda64 heading is neat--especially with the callback to the pre-release OoT name.

Of course, then another team started a Minish Cap project, and now the name is a bit out there.

It’s funny how people still call it Zelda 64 more than 20 years later, despite that not being its actual name.
It's funny that after 20 years you still bother....
I wonder if this will lead to new speedrunning strategies? The existing strategies are already mind-blowingly complicated and make use of bugs, glitches and quirks that feel nearly impossible to discover.
So if they have C Functions for all the things, this mean I could improve render depth? I just played OOT with mupen64 and realized that e.g. when you run around in Kokiri Forest some object like npc's will appear only when you are pretty close to them. I guess this was done in the past because of computing and rendering powers, right? Would be nice to tweak this.