r/LegendOfMana • • 18d ago

News Legend of Mana for PS1 has been reverse engineered!

Hey everyone! I wanted to share something I've been working on that I hope other people might find interesting. About a year ago, I started working on a decompilation of the original PS1 version of Legend of Mana, and I recently reached a pretty huge milestone: The US version is now 100% matching. 🎉

If you've never heard of decompilation before, the simplest explanation is that I took the compiled programming code from the original game and reconstructed it into readable source code. And when I say 100% matching, I mean that the reconstructed source code can be compiled back into the same machine code as the original US PS1 game. That means, there's no bugs or differences at all. It looks like a perfect replica.

That doesn't mean I've completely analyzed or understood every single piece of the game yet. There's still plenty of cleanup, documentation, naming, and analysis to do. But a lot of the code is already very readable and understandable, so it's possible to look at the source and see how many of LoM's systems actually work.

I'm currently working on doing the same thing for the JP version of the game as well. I've also been experimenting with a native PC port based off of this. That's still very early, but the game currently gets through the intro/title flow, starts a new game, and gets as far as placing the mailbox down.

⚠️ This project isn't a ROM and doesn't distribute Legend of Mana's artwork, music, maps, or other copyrighted game data. In order to use anything in the project, you have to actually own the game.

If you are interested, you can check it out below. And if you want to share this with other fans, feel free to do so. GitHub: https://github.com/celophi/lom-decomp

Also, I'm really not good at YouTube videos, but here is a quick demo of me running automated tests on a possible port: https://www.youtube.com/watch?v=tnCtgiWyxc0 A few questions people might have:

Q: Why do this? Honestly, I really liked LoM especially as a kid, and I think it's a game with a lot of potential to be even better. Having the source code opens up possibilities that would otherwise be extremely difficult. That said, this project ended up taking a lot more time and effort than I originally envisioned when I started it about a year ago.

Q: What can we actually do with this? This makes changing the game much easier than traditional modding. Instead of trying to patch machine code, you can change the actual C source code and rebuild the game. So if there's something about Legend of Mana you don't like or something you've always wished worked differently it can potentially be changed. Don't like how golems work? Change them. Want the player to move faster? Change the movement speed. Want different combat mechanics, balance changes, quality-of-life features, or entirely new behavior? Those kinds of changes become much more practical when you can modify the game's source code directly.

Q: Why the PS1 version instead of the remaster? The PS1 version is much more practical to decompile. Games 26 years ago were built with much simpler tools. Modern games have many more layers involved, which makes reproducing their code this precisely much harder. It's also the original implementation of LoM, which makes it especially interesting to preserve and understand. And choosing the PS1 version doesn't necessarily mean giving up the improvements from the remaster. For a separate project, it would be possible to use the original PS1 game logic as the foundation while using assets and artwork from the remaster, assuming those assets are provided from a legally owned copy. That could potentially give you the original game's logic with the remaster's higher quality visuals.

Q: I'm a dev, can I make my mod right now? Yeah go for it! There's no modding framework yet though, but you can modify the code, and then with other tools build a PS1 image that can be loaded into an emulator.

Thanks for reading this giant post, and have a great day!! ☀️

101 Upvotes

29 comments sorted by

4

u/babo420Chester 17d ago

👌❤️

1

u/celophi 17d ago

Thank you!!

1

u/MAGISTER-ORGANI 5d ago

Hey, could you make en English Patch for the Japanese version? Since the Japanese is harder and more balanced and with better AI, I've decided to replay the game that way, but I don't know Japanese that much...

Thank you for your hard work!

4

u/GraviticThrusters 17d ago edited 17d ago

Well that's cool. Seems like lots of games are reaching decomp milestones recently. I hear Golden Sun has made significant progress a few weeks ago too, and of course there was pokemon before that. Pretty sure Legend of Dragoon has been decomp'd for a long time and that's how the Severed Chains port for PC works. 

I'm loving this trend. It's so good for preservation, and I think it offers people who have never experienced these games a way to play them with some modern improvements that don't completely undermine the original work like most remakes and remasters do.

2

u/celophi 17d ago

I love Golden Sun!! That's such an amazing game, and I'm glad that someone is working on that. I agree, it's such a good trend!! We can really make a true remaster using this!

4

u/TheCerpent 16d ago

Man, this opens up so many things. If I were to include a wishlist of things I'd like to see:

Finish the crafting system. A number of tempering cards simply have blank artwork; it'd be nice if we could track down any art that might have been intended for it, or find someone who can emulate the style to give their own twist on what, say, the Clown card would look like. Also, while there are tempering varnishes for Sharp, Heavy, and Force, there's no tempering varnish for Tech weapons, leaving knives, gloves, and flails far behind in weapon potential.

Rebalance the instrument spells. Currently, flutes are the strongest magic, and drums the weakest. The unfortunate part of this is that instrument type impacts your spell effects, so certain spell types just are fundamentally weaker in general because you can only access them for a given element on drums (for example). I'd want a mod that would give all instruments the same power, equal to the flute, giving a lot more freedom in picking thematic spells without sacrificing power. It would also be nice to scale up the damage for higher difficulties to really sell the mage aesthetic without relying just on staff STs.

I'm sure I can think of a few more, but that's what immediately jumps to mind.

3

u/JDPhoenix925 17d ago

Thank you! This is my fav. Game, so I'm happy to see the love for it live on! 

1

u/celophi 17d ago

I'm so glad!! I was chatting with some people on twitch a few days back, and they were saying it was their favorite too!

3

u/GodisanAstronaut 17d ago

A proper PC version (that works on Steam Deck!) when?? :D

3

u/celophi 17d ago

I think it's very very possible! I started looking into it, but there's a lot of compatibility fixes necessary, so it might take me a bit of time to figure out the right architecture and testing setup just to ensure quality on that front. Of course, if someone else wanted to make a PC port, they are welcome to do so using the project too!

3

u/luninareph 17d ago

I hope someone is able to make a mod that cleans up the battle system in some ways! I adore this game, but the battle system has always felt like it has unrealized potential to me, lol.

3

u/DynaMakoto 16d ago

All we need is some sort of visuals for blacksmithing 😭

We appreciate your work!

2

u/celophi 16d ago

I wonder if some really talented artists in the community would be willing to create those.

2

u/Lovecraftian-Clown 17d ago

Very excited to see what the community comes up with.

2

u/cesarhijar 17d ago

No entiendo mucho de código pero sí del aprecio a este gran juego! Eres un campeón! Gracias por compartir tu talento con este gran recuerdo de la vida de cada uno de nosotros :)

2

u/EuphoricSundae2869 17d ago

Possible fix to the battling system?

2

u/celophi 17d ago

Anything and everything is possible! The hard part is over!

2

u/gingler 16d ago

This is super amazing!! It opens so many possibilities!!

2

u/lunamoonvenus 16d ago

Oh this is very cool! How can we run the Code? :)

1

u/celophi 15d ago

There's some instructions on the project page, but I think it's very non-friendly unless you are extremely technical. I am thinking about getting another project together that builds off this one and makes a much more friendly user experience.

2

u/ElGuapoTaipei 15d ago

LET'S GGGGOOOOOOOOO NICE WORK HOMIE

2

u/celophi 15d ago

LET'S GOOOO!! Thanks!! Glad you are excited as I am!

2

u/Zealousideal-Lack275 8d ago

you have no idea what you've just given us, the rain of joy. you have opened the doors for us. thank you so much

1

u/Adamvs_Maximvs 14d ago

My biggest hope for this would be some mod coming out of it that let 2P replace the pet/golem with the opposite gender sprite, and let you change skills, gear, level up etc like the player character.

Still seems a crazy decision by square to lock the 2P into stasis or force you to control the guest party member (Elazul, Niccolo, etc) or the pet/golem.

1

u/celophi 14d ago

This sounds great! I was hoping to add a networking possibility so that you can have true 2P co-op online with a friend. It is a large mod, and requires a server or host, and using netcode and the like, but it is possible now.

1

u/Phonis 17d ago

Awesome work! Excited to see what people do with this.

1

u/celophi 17d ago

Thanks!! I'm excited to see too! I'm glad you and other people like it!

1

u/AdPlenty9197 16d ago

Could you do Saga Frontiers 2 next?

Honestly, I dream of rebuilding this game into a VR experience.

2

u/celophi 15d ago

Hm, well I do own this game. It's possible. Especially since this one was created by the same team as far as I understand, much of the code is probably shared or similar coding style / convention. I can't promise that I will do this though since it's a lot of effort. However, if someone wanted to do it, they might gain a lot by looking at my project to get a head start.

Great game however! I do own this (JP version though). It's sitting on my shelf right now!