News:

11 March 2016 - Forum Rules

Main Menu

Replacement for Hyrule Magic

Started by redmagejoe, March 31, 2019, 02:36:25 PM

Previous topic - Next topic

redmagejoe

So this may come off as a little presumptuous, especially since I haven't worked with the tool, but with the recent process of helping Eyeballkid fix up his v0.2 of Zelda3: Hyrule Explorer to v0.3, and trawling around the Zeldix Forums, it occurs to me that while HyruleMagic is a reliable old horse that's been around for many years and most Link to the Past hackers would swear by it, it suffers from a rather nasty problem under the hood. Hyrule Magic seems to rearrange and heavily modify data in ROM even when simply opening the file and not changing it, and while it (mostly) does exactly what people want it to do and probably isn't a problem for people doing massive, complete rework hacks that already heavily change the game data, this seems like a terribly messy, spaghetti-code way of modifying CHR data.

As an example, Hyrule Explorer is a very subtle, minimally-modified patch for Link to the Past, yet rather than changing a few addresses in ROM, it expands the size of the ROM and irreparably modifies large swaths of data that seem completely unrelated to changes being made. This would, in most cases, result in compatibility issues and (speaking from experience) makes hex-comparison in the hopes of fixing bugs a completely unfeasible nightmare. Maybe it's just the OCD dev mentality in me, but since it's been 13 years now, has anyone toyed with the idea of writing up a new tool to act as a modern replacement for Hyrule Magic? Or is this a non-issue for most hackers? Just floating the idea out there and eager to see how other people feel about the prospect of a less-invasive Link to the Past CHR editor.

Jorpho

Quote from: redmagejoe on March 31, 2019, 02:36:25 PMit occurs to me that while HyruleMagic is a reliable old horse that's been around for many years and most Link to the Past hackers would swear by it
People call Hyrule Magic "reliable" ?  It was my understanding that it was in general almost hopelessly unusable, and that owing to the complexity of the ROM, there was little hope of anything better coming along.  Are people still actually making ROM hacks with it these days?
This signature is an illusion and is a trap devisut by Satan. Go ahead dauntlessly! Make rapid progres!

FCandChill

#2
The current build of Hyrule Magic on Romhacking.net is outdated. MathOnNapkins released the source code for Hyrule Magic and is currently improving it:
https://bitbucket.org/MathOnNapkins/hmagic

The repo includes MANY bugfixes.

What prompted the release given years of keeping it private per Sephiroth3's wish? Because of a bad compiler, half the source code was included in the EXE of recent Hyrule Magic releases. MathOnNapkins decided he might as well make it public.

There's also ZScream by Zarby89. The program has been in development for roughly 8 years and is far from complete IIRC. The development for this one is scattered to say the least...
https://github.com/zarby89

Quote from: redmagejoe on March 31, 2019, 02:36:25 PM
it occurs to me that while HyruleMagic is a reliable old horse that's been around for many years and most Link to the Past hackers would swear by it, it suffers from a rather nasty problem under the hood.

Hyrule Magic corrupting ROMs was a common occurrence. It didn't care about data limits and will overwrite data. The worst part is that it hardly supported ROM expansion aside from dungeon headers... I can't speak for the current build though ... because it fixes a lot of issues.

eyeballkid

Quote from: Jorpho on March 31, 2019, 03:58:56 PM
Are people still actually making ROM hacks with it these days?

Yes... I can assure you that they are.



There's also another improved version compared to what is on RHDN:
http://www.zeldix.net/t1017-sungodportal-s-hyrule-magic-hack

This is what I use(d)...



Quote from: FCandChill on March 31, 2019, 04:09:33 PM
The current build of Hyrule Magic on Romhacking.net is outdated. MathOnNapkins released the source code for Hyrule Magic and is currently improving it:
https://bitbucket.org/MathOnNapkins/hmagic

The repo includes MANY bugfixes.

What prompted the release given years of keeping it private per Sephiroth3's wish? Because of a bad compiler, half the source code was included in the EXE of recent Hyrule Magic releases. MathOnNapkins decided he might as well make it public.

As you wrote, there wasn't the complete source code available at the start. Are you sure this is in a working state currently?



Quote from: FCandChill on March 31, 2019, 04:09:33 PM
There's also ZScream by Zarby89. The program has been in development for roughly 8 years and is far from complete IIRC. The development for this one is scattered to say the least...
https://github.com/zarby89

Can you make sense of it, though? To my understanding, it contains 4 different tries on writing a new editor for ALttP...



There's also this:
https://github.com/superskuj/Zeldix-Magic

However, at least on the github page updates have stopped already 2 years ago, and they have restricted the access to the forum page of the project...


eyeballkid

#4
PS: Since MathOnNapkins doesn't provide builds, here's the current code compiled:

https://we.tl/t-k5oZ5xAAr1

There are different branches. Some with more recent updates than the master branch:

https://bitbucket.org/MathOnNapkins/hmagic/branches/

master   2018-10-26
staging1 2018-12-03
staging2 2019-03-15
staging3 2019-02-18

I couldn't build staging2, since a file (hm-res.h) is missing. The others can be found in the archive above.


PPS: For anyone interested, what redmagejoe is referring to is a bug introduced by Hyrule Magic that needed Conn's excellent knowledge to be fixed. See here:

http://www.zeldix.net/t1287p25-zelda-iii-hyrule-explorer#30342

http://www.zeldix.net/t1287p50-zelda-iii-hyrule-explorer#30359

FCandChill

#5
Quote from: eyeballkid on April 01, 2019, 06:09:21 AM
PS: Since MathOnNapkins doesn't provide builds, here's the current code compiled:

You didn't provide a download link.

April 01, 2019, 07:25:47 PM - (Auto Merged - Double Posts are not allowed before 7 days.)

Quote from: eyeballkid on April 01, 2019, 03:26:13 AM
There's also this:
https://github.com/superskuj/Zeldix-Magic

However, at least on the github page updates have stopped already 2 years ago, and they have restricted the access to the forum page of the project...

There's a more update-to-date repo for this project (last updated in 2018). It's basically dead at this point though...
https://bitbucket.org/clampsy/zeldix-magic

Quote from: eyeballkid on April 01, 2019, 03:26:13 AM
Can you make sense of it, though? To my understanding, it contains 4 different tries on writing a new editor for ALttP...
Not really. Zscream looks cool, but the code is bad. See this file for example...
https://github.com/Zarby89/ZScreamMagic-4/blob/master/ZScreamMagic/PaletteViewerMap.cs

There's a lot of copy-pasting.

eyeballkid

Quote from: FCandChill on April 01, 2019, 07:00:55 PM
You didn't provide a download link.

Hmm, I think I did?! It's all in here:

https://we.tl/t-k5oZ5xAAr1

Just checked, it works for me...


Thanks for the updated Zeldix Magic link.


EDIT: I edited the previous post. I had ordered the text badly. That was probably the reason why you have been confused about the missing download link.

FCandChill

Quote from: eyeballkid on April 02, 2019, 03:43:03 AM
Thanks for the updated Zeldix Magic link.

No problem. The program is far from complete, however, the source is relatively cleaner than Hyrule Magic's and Zscream's. It handles data structuring a lot better... Heck, I've used the dialogue editor code as a basis for my own editor.

A lot of the dungeon reading and writing looks complete. It's just the GUI for the dungeon editor that needs to be done.

Quote from: eyeballkid on April 02, 2019, 03:43:03 AM
EDIT: I edited the previous post. I had ordered the text badly. That was probably the reason why you have been confused about the missing download link.

Thanks!

eyeballkid

Quote from: FCandChill on April 02, 2019, 05:46:44 PM
A lot of the dungeon reading and writing looks complete. It's just the GUI for the dungeon editor that needs to be done.

Hmm. It's strange: I feel that writing the code that deals with the ROM itself is the actual hard part. And writing the GUI code seems to be the part which actually many more people could achieve since more common coding skills are needed. Nevertheless, almost all projects suffer from a bad or missing GUI in the end...

I would actually be very much interested in contributing to any of these projects. But they are all locked into Windows / Visual Studio, which I don't use. If someone was up for an ALttP editor in Python, I'd be all over it. Alternatively, something C++ using open source / cross platform tools would be great as well.

I wonder how hard it would be to port Hyrule Magic from Win32 to Qt ...?!

redmagejoe

#9
I know that this is a very old thread, but I feel that this question is very relevant and I am curious about the finer details of a project that only recently came to my attention.

https://www.romhacking.net/utilities/1507/

What can anyone tell me about the stability/improvements of ZScream over Hyrule Magic? Is this built upon Hyrule Magic, or a ground-up attempt at replacing it? Does it suffer from the same ROM-corruption issues as Hyrule Magic? Could this, in theory, be used to reverse engineer some level edit patches and make them more compatible with newer ones, such as the recently released https://www.romhacking.net/hacks/6437/ ? As it stands, I have a carefully numbered, ordered list (load order) of the all the patches to use on a fresh Zelda 3 ROM because of how touchy one of the patches, made in Hyrule Magic, is. It would be a dream come true to hear that there was finally a feasible replacement for the tool.

Quote from: FCandChill on March 31, 2019, 04:09:33 PM
There's also ZScream by Zarby89. The program has been in development for roughly 8 years and is far from complete IIRC. The development for this one is scattered to say the least...
https://github.com/zarby89

It does seem as though all that time in development finally paid off, as it appears the tool was released on this site only a month ago. I'm eager to know what people's impressions of it are.