Romhacking.net

Romhacking => Personal Projects => Topic started by: Xeeynamo on July 07, 2009, 09:46:09 am

Title: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Xeeynamo on July 07, 2009, 09:46:09 am
Forgot totally the old Megaman X Editor that I was develop and wait the new version completely rewritten and full optimized!
There isn't much to say, only that this new editor is a lot faster than the previous editor, bugfree (I hope :P), the next release will have a complete support for MMX2, MMX3 and object editor.

DOWNLOAD (http://digitalwork.altervista.org/digitalwork/index.php?page=mmxe).
My official blog to see more updates (http://xeeynamo.blogspot.com).
(http://3.bp.blogspot.com/_cAvEek8l8OE/TMyU-zfUPYI/AAAAAAAAAGo/cluNMZX62nM/s1600/megaedx_scr.png)
Title: Re: Megaman X Editor
Post by: Tauwasser on July 07, 2009, 10:03:45 am
Please show some screenshots and elaborate a bit more on the planned features, thanks.

cYa,

Tauwasser
Title: Re: Megaman X Editor
Post by: Nightcrawler on July 07, 2009, 10:07:55 am
You're using Vista or newer specific features such as WPF? or maybe C# 3.0 specific features? You'd be the first ROM hacking utility to ever do so thus far I think. Otherwise, why are you requiring .NET 3.5? You can target 2.0 and be much more accessible to non Vista or newer users. As we've seen around here, most XP users don't have .NET 3.5. We're lucky they have any version of .net at all, let alone are willing to upgrade anything.

Just trying to save you a headache or two since this cycle repeats often around here. Everybody who uses Visual Studio 2008 usually falls into this trap since it targets 3.5 by default. It was geared primarily for Vista after all.

It will also make it more likely to be compatible with Mono which would make it cross platform.
Title: Re: Megaman X Editor
Post by: Killa B on July 07, 2009, 10:43:27 am
So... After seeing that the download link was an .exe on Rapidshare, I wasn't so sure I could trust it. Since I'm on Linux, though, what's the worst it could do besides not work?

Well, I downloaded it. It seems pretty legit. I opened two Megaman X roms (1.0 and 1.1, both headered) and messed around. I didn't actually edit anything, but the text viewer seems to work as expected. It's also the first program that I have ever successfully run through Mono, which is interesting.

So, if anyone else suspects that this is malware: I'm pretty confident that it isn't. Of course, I'm not responsible for any damages that may be done to your computer or your genitals by running this program.

(http://img139.imageshack.us/img139/3536/themoreyouknow.jpg)
This post has been brought to you by genuine concern and nothing better to do.
Title: Re: Megaman X Editor
Post by: Xeeynamo on July 07, 2009, 10:57:18 am
You're using Vista or newer specific features such as WPF? or maybe C# 3.0 specific features? You'd be the first ROM hacking utility to ever do so thus far I think. Otherwise, why are you requiring .NET 3.5? You can target 2.0 and be much more accessible to non Vista or newer users. As we've seen around here, most XP users don't have .NET 3.5. We're lucky they have any version of .net at all, let alone are willing to upgrade anything.

Just trying to save you a headache or two since this cycle repeats often around here. Everybody who uses Visual Studio 2008 usually falls into this trap since it targets 3.5 by default. It was geared primarily for Vista after all.

It will also make it more likely to be compatible with Mono which would make it cross platform.
Oh, i know that is a problem for Windows XP Users :S but when i started this project, i has afraid that with .net framework 2.0 most functions don't works. Yesterday (Before the last compile) I've try to switch from 3.5 in 3.0 or 2.0, but the compilator give me most errors. Now I think that rewrite the entire program with .Net 2.0 in C# :P. Oh, is the second editor ^^ the first is it http://digitalwork.altervista.org/digitalwork/index.php?page=s3kse

Please show some screenshots and elaborate a bit more on the planned features, thanks.

cYa,

Tauwasser
See the first post now =)
Title: Re: Megaman X Editor
Post by: Nightcrawler on July 07, 2009, 12:53:32 pm
What errors do you get out of curiosity?
Title: Re: Megaman X Editor
Post by: Xeeynamo on July 07, 2009, 01:51:36 pm
So... After seeing that the download link was an .exe on Rapidshare, I wasn't so sure I could trust it. Since I'm on Linux, though, what's the worst it could do besides not work?

Well, I downloaded it. It seems pretty legit. I opened two Megaman X roms (1.0 and 1.1, both headered) and messed around. I didn't actually edit anything, but the text viewer seems to work as expected. It's also the first program that I have ever successfully run through Mono, which is interesting.

So, if anyone else suspects that this is malware: I'm pretty confident that it isn't. Of course, I'm not responsible for any damages that may be done to your computer or your genitals by running this program.

(http://img139.imageshack.us/img139/3536/themoreyouknow.jpg)
This post has been brought to you by genuine concern and nothing better to do.
It's totally free of dangerous code, because the software don't touch the register or the system folder ^^. Because I don't know the english very well ( :banghead: ) you say that my software and other programs written with C#, runs with an emulator/interpretator on Linux? What distribution of Linux you use?

What errors do you get out of curiosity?
(I've translated the error from italian to english)
Code: [Select]
Error CS0234:  The type or the name of 'Linq' don't exist in 'System';=O wait, I've removed every referement on "Linq" and now work when I set .Net Framework 2.0!! =D now I test it on a Virtual OS with a clean setup of Windows XP
Title: Re: Megaman X Editor
Post by: Nightcrawler on July 07, 2009, 02:16:34 pm
(I've translated the error from italian to english)
Code: [Select]
Error CS0234:  The type or the name of 'Linq' don't exist in 'System';=O wait, I've removed every referement on "Linq" and now work when I set .Net Framework 2.0!! =D now I test it on a Virtual OS with a clean setup of Windows XP

Awesome! Give this a try and see how compatible it might be with Mono for the Linux and Mac guys:

http://mono-project.com/MoMA

Many of my simpler .NET programs are compatible as is with no modification. Some have only a minor thing or two you can change. Maybe yours will work. Doesn't hurt to check. :)
Title: Re: Megaman X Editor
Post by: Xeeynamo on July 07, 2009, 02:38:05 pm
(I've translated the error from italian to english)
Code: [Select]
Error CS0234:  The type or the name of 'Linq' don't exist in 'System';=O wait, I've removed every referement on "Linq" and now work when I set .Net Framework 2.0!! =D now I test it on a Virtual OS with a clean setup of Windows XP

Awesome! Give this a try and see how compatible it might be with Mono for the Linux and Mac guys:

http://mono-project.com/MoMA

Many of my simpler .NET programs are compatible as is with no modification. Some have only a minor thing or two you can change. Maybe yours will work. Doesn't hurt to check. :)
Well, is compatible with Mono 2.4 :thumbsup: but in a clean setup of Windows XP, it don't work >.<, but probabilly WinXP haven't preinstalled .Net 2.0
http://img269.imageshack.us/img269/5024/erroridx.png
Title: Re: Megaman X Editor
Post by: Lleu on July 07, 2009, 03:09:31 pm
That's correct, XP does not come with .NET 2.0.  I think it only comes with .NET 1.0, which is old enough to be used by pretty much nothing other than the XP Media Center applications.  You will need to either install .NET 2.0 or Mono.  Or both.
Title: Re: Megaman X Editor
Post by: Nightcrawler on July 07, 2009, 06:43:09 pm
That's great to hear! I'm sure people will appreciate your efforts. That's all that can be realistically expected of you in my opinion. .NET 2.0 doesn't come with XP, but many XP users have at least it by now. You can only bend over backwards so far as a developer for certain groups of stubborn users. Where you're at is a good compromise if you ask me. :)  :cookie:
Title: Re: Megaman X Editor
Post by: Killa B on July 08, 2009, 12:23:22 am
you say that my software and other programs written with C#, runs with an emulator/interpretator on Linux?
Correct. :) Not all programs written in C# (or other .NET languages) will run, but your program works fine.

What distribution of Linux you use?
Arch Linux i686, running Mono version 2.4
Title: Re: [0.0.5] Megaman X Editor (July/8/2009)
Post by: Xeeynamo on July 08, 2009, 12:06:27 pm
Release a new subversion :)
0.0.7:
-Improved the GUI Mode (Now the Text Editor window can be resized)
-Added more offsets for text
Title: Re: [0.0.7] Megaman X Editor (July/10/2009)
Post by: FaustWolf on July 11, 2009, 01:56:07 pm
Xeeynamo, I can't wait for sprite editing capability in this! How possible do you think it would be to implement things like the double (or triple)-charge shots from X2 and X3? For that matter, any idea how much the game engines in X2 and X3 even differ from the first one?
Title: Re: Megaman X Editor
Post by: Disch on July 11, 2009, 11:23:37 pm
That's great to hear! I'm sure people will appreciate your efforts.

Hear hear!

Availability on other platforms is always fantastic.  Bravo!
Title: Re: [0.2] Megaman X Editor (July/15/2009)
Post by: Xeeynamo on July 13, 2009, 08:05:04 am
Xeeynamo, I can't wait for sprite editing capability in this! How possible do you think it would be to implement things like the double (or triple)-charge shots from X2 and X3? For that matter, any idea how much the game engines in X2 and X3 even differ from the first one?
I don't know if this is possible :S and I don't know the differences from the X2 and X3 engine...

Oh, the Text Editor is finish!! Now the final version 0.1 is released ;) look the first post

EDIT:
Preview of a new function of the version 0.2: Checkpoint editor and Border editor for the levels: http://www.youtube.com/watch?v=P0l9IJKlTPA&fmt=18

EDIT2:
Version 0.2 released! Oh, I don't know how develope a checksum fixer, someone can help me? =D
Title: Re: [0.2] Megaman X Editor (July/15/2009)
Post by: Nightcrawler on July 15, 2009, 09:00:52 am
http://www.geocities.com/joecool22us/csum.htm

As an alternative, you can check out the source code to any emulator that tells you if the checksum is good or bad. ZSNES and SNES9x do so for starters.

Are you going to submit this utility to the site?
Title: Re: [0.2] Megaman X Editor (July/15/2009)
Post by: DarknessSavior on July 15, 2009, 02:10:04 pm
I tried this out yesterday, and I'm quite impressed.

However, I have one gripe (which is also a suggestion). For editing text, you limit the text to one line on the editor screen. You should make it a larger text box, so that the entire line can be viewed at once.

Other than that, awesome job!

~DS
Title: Re: [0.2] Megaman X Editor (July/15/2009)
Post by: Xeeynamo on July 16, 2009, 07:10:22 am
http://www.geocities.com/joecool22us/csum.htm

As an alternative, you can check out the source code to any emulator that tells you if the checksum is good or bad. ZSNES and SNES9x do so for starters.

Are you going to submit this utility to the site?
I submit this utility in next release ;) today I go in holiday (France =D) and I will bring my notebook. I've the sourcecode of snes9x and more for working on editor! When I will return, i will release a new version!!
I tried this out yesterday, and I'm quite impressed.

However, I have one gripe (which is also a suggestion). For editing text, you limit the text to one line on the editor screen. You should make it a larger text box, so that the entire line can be viewed at once.

Other than that, awesome job!

~DS
Thanks ^.^
Btw the window is resizable :D http://img401.imageshack.us/img401/4452/51502675.jpg
Title: Re: [0.2] Megaman X Editor (July/15/2009)
Post by: Jigglysaint on July 16, 2009, 01:49:57 pm
I've looked at X3 and it seems that aside from a few differeces, it seems that they have similar engines.  I think adapting an editor for X2 and 3 shouldn't be hard once all the data for X has been collected.  Speaking of which, what data has yet to be found?
Title: Re: [0.2] Megaman X Editor (July/15/2009)
Post by: DarknessSavior on July 16, 2009, 02:39:18 pm
The window being resizable is better than nothing. But it would look cleaner if you were to make an actual box for text to go into.

~DS
Title: Re: [0.2] Megaman X Editor (July/15/2009)
Post by: flashman on July 24, 2009, 12:30:26 pm
This project is ... PURE AWESOMENESS!!!

I've always dreamed of something like this because i wanted to create a very interesting new Megaman game but as i'm lacking the skills to hack with the tools already existing, i very much apprechiate your work!

I mainly would need sprite hacking, so please keep this project alive!!!
Title: Re: [0.2.8] Megaman X Editor (July/12/2009)
Post by: Xeeynamo on July 27, 2009, 06:52:41 am
Released a new version :)
- Palette Editor added
- Fixed a bug on the Start Point Editor

EDIT:
Another version are released:
Quote
This is a particolar version of Megaman X Editor. Because I've lost the source code of the 0.2.7 version (See below) this is based on 0.2.5. The only new feature of this version (Called 0.2.8) is the menu "Other". This version don't have the features of the version 0.2.6 and 0.2.7 (But in the same zip archive, you can find the version 0.2.7) and some functionality are disabled like Level Editor and Start Point Editor and the Palette Editor don't work well.

But the source code of the version 0.2.7 is recoverable?
Good question! Well, my homepc is broken :P my motherboard is burned. I've saved the two hard drives but there is a BIG problem... The two hard drives used the RAID0 and now I use a stupid pc (EeePC 1000H) and I can't connect the two hard disk on this pc because it support only one drive and only in IDE mode (Not RAID mode >.<). Oh, if you don't know, the eeepc 1000h have a stupid 1.6ghz atom processor and a 10inch monitor and for me is VERY hard to work with Visual Studio :P. Be patience ;)
Title: Re: [0.3.0] Megaman X Editor (August/18/2009)
Post by: Xeeynamo on August 16, 2009, 06:00:47 am
0.2.9 version released :thumbsup:

Quote
- Improved the Checksum Fixer (4x faster =P)
 - Correct a small bug in Checksum Fixer that affect the lasts 0x200 byte of rom
 - Added more options on Engine Editor
 - Full support with normal and headered MMX roms

Quote
The version 0.2.9 have a small bug that corrupt the non-headered mmx roms with Palette Editor and Checkpoint Editor. I will fix this in 0.3 version ;)


Edit: I'm working on 0.4 version, that will include a sprite editor :)
(http://img9.imageshack.us/img9/7008/69428396.png)
Title: Re: [0.3.0] Megaman X Editor (August/19/2009) [SPRITE EDITOR IN DEVELOPING!!!]
Post by: misterj on August 23, 2009, 11:53:27 pm
Looking good, man.
I think it is important to second what others are saying about the text editor, though. CR/LFs should operate as the line separators rather than those special characters.
Title: Re: [0.3.0] Megaman X Editor (August/19/2009) [SPRITE EDITOR IN DEVELOPING!!!]
Post by: Gideon Zhi on August 24, 2009, 12:09:18 am
How malleable are the editor's addresses? I guess what I'm asking is, hypothetically, if I expanded the ROM, and added more levels to the game's level loader, would I be able to redirect the editor to look at the new pointer table?

I'm kind of talking out of my arse here, but what I'd really like to do is add a few more levels and add some nonstandard ways of getting into them. Not necessarily through the standard stage select screen.
Title: Re: [0.3.0] Megaman X Editor (August/19/2009) [SPRITE EDITOR IN DEVELOPING!!!]
Post by: Zero on August 24, 2009, 04:08:23 pm
 :banghead: lol I hope the sprite editor will be finsihed soon man.
Title: Re: [0.3.0] Megaman X Editor (August/19/2009) [SPRITE EDITOR IN DEVELOPING!!!]
Post by: Xeeynamo on August 26, 2009, 06:46:04 pm
omg, I've some hard problems :(
15 july => Holiday
24 july => Return at home
28 july => My home pc has burned (Motherboard >_>)
An day of august => Working with my eeepc on a old sourcecode backup of mmxe and released 0.2.8 version
10~16 august => Recovered the source code of 0.2.7, added the feature of 0.2.8 and released 0.2.9 version
18 august => Released 0.3.0 version and working on 0.4.0 version
22 august => BURNED THE PROCESSOR OF MY NOTEBOOK!!!!!!!
Now I'm with a friend's pc. I hope that the project will be resumed at september, when I repair my home pc :(
Title: Re: [0.3.0] Megaman X Editor (August/19/2009) [SPRITE EDITOR IN DEVELOPING!!!]
Post by: Corvus on August 26, 2009, 09:49:16 pm
I registered on this forum because, and only because, I wanted to say thank you. I have been waiting for a long time for someone to create a ROM hacking tool for X. I'm sorry to hear about your PC trouble, and wish you the best of luck.
Title: Re: [0.3.0] Megaman X Editor (August/19/2009) [SPRITE EDITOR IN DEVELOPING!!!]
Post by: Zero on August 27, 2009, 03:00:29 pm
I'm just like, a little impatient for the sprite editor to be finished man. So I can make Zero, with the hair, and make the game about Zero's story. If I can.. I'm new but I will figure things out. Oh yea, also make a sprite editor for Zero's and Megaman X's weapons. Just a suggestion.

August 27, 2009, 03:01:15 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
But it's all good. Take your time.  :)
Title: Re: [0.4.0] Megaman X Editor (September/07/2009) [WITH SPRITE EDITOR!!!]
Post by: Xeeynamo on September 06, 2009, 06:54:09 pm
How malleable are the editor's addresses? I guess what I'm asking is, hypothetically, if I expanded the ROM, and added more levels to the game's level loader, would I be able to redirect the editor to look at the new pointer table?

I'm kind of talking out of my arse here, but what I'd really like to do is add a few more levels and add some nonstandard ways of getting into them. Not necessarily through the standard stage select screen.
No, the editor have static addresses :( I'm not an expert of ROM hacking and for arrive at this point, I've studied for days the mmx rom! I've some problems because I don't know how I can find addresses like the level layout and I don't know if this game use compressed graphic and where there placed...
I registered on this forum because, and only because, I wanted to say thank you. I have been waiting for a long time for someone to create a ROM hacking tool for X. I'm sorry to hear about your PC trouble, and wish you the best of luck.
Thanks :) I'm honored
I'm just like, a little impatient for the sprite editor to be finished man. So I can make Zero, with the hair, and make the game about Zero's story. If I can.. I'm new but I will figure things out. Oh yea, also make a sprite editor for Zero's and Megaman X's weapons. Just a suggestion
But it's all good. Take your time.  :)
When the editor will become complete, you can make all hacks that you want =D. I hope that my software is helpful ^^.
Oh, now I use a stupid pc XD an old athlon based pc with 512 of ram >_>

PS. 200 download reach on my website O_O
Title: Re: [0.4.0] Megaman X Editor (September/07/2009) [WITH SPRITE EDITOR!!!]
Post by: justin3009 on September 07, 2009, 01:00:43 pm
This is incredibly promising!  I've always wanted to make a MMX hack, but it's still not quite possible but this is most definitely a major step up!
Title: Re: [0.4.0] Megaman X Editor (September/07/2009) [WITH SPRITE EDITOR!!!]
Post by: azoreseuropa on September 08, 2009, 08:26:51 am
@Xeeynamo,

Good job!

Can you check your PM (Private Message) if you don't mind ? Thanks again. :)

EDIT: Thank you for replying back. :)
Title: Re: [0.4.5] Megaman X Editor (September/09/2009) [WITH SPRITE EDITOR!!!]
Post by: Xeeynamo on September 09, 2009, 04:22:30 am
Okay, new version released!!!
Quote
- Sprite Sheet implemented on Sprite Editor
 - LightBlue theme added (Now MMXE have an optimize graphic on WinXP)
 - MMXE now use Tahoma font
 - New functions on Text Editor
 - New colors in the menu of Text Editor
 - Length check on Text Editor
 - Small speed and size optimizations in the code of Palette Editor
 - Now in Palette Editor you can see the selected color in decimal and hex
 - Added a control on Checksum Fixer that says if the ROM is headered or not
 - Correct a critical bug in 0.4.0 version that crash when you open the editor
 - Correct a bug in Palette Editor that cause a malfunction on Reset button
     when you select a palette on the grid
 - Correct a bug in Sprite Editor that when you put a custom value for sprite or palette and
     you use the scrolling, return the old value in the textbox
 - Correct a bug in Sprite Editor that cause infinite the scrolling of sprite

(http://img171.imageshack.us/img171/5150/immaginezq.png)
Title: Re: [0.4.0] Megaman X Editor (September/07/2009) [WITH SPRITE EDITOR!!!]
Post by: Gideon Zhi on September 09, 2009, 04:26:12 am
How malleable are the editor's addresses? I guess what I'm asking is, hypothetically, if I expanded the ROM, and added more levels to the game's level loader, would I be able to redirect the editor to look at the new pointer table?

I'm kind of talking out of my arse here, but what I'd really like to do is add a few more levels and add some nonstandard ways of getting into them. Not necessarily through the standard stage select screen.
No, the editor have static addresses :( I'm not an expert of ROM hacking and for arrive at this point, I've studied for days the mmx rom! I've some problems because I don't know how I can find addresses like the level layout and I don't know if this game use compressed graphic and where there placed...

I'd be happy to help you find this stuff if you'd think it'd be useful. I actually toyed with MMX myself once, a good long time ago. Don't think any of that work remains, but given the physical starting address of one of the levels it should be a fairly simple matter to track it back to its origin.
Title: Re: [0.4.5] Megaman X Editor (September/09/2009) [WITH SPRITE EDITOR!!!]
Post by: Zero on September 11, 2009, 01:07:46 pm
Looks awesome bro, it's kinda hard to use lol but will get used to it. Uhm, if you can with your next version coming out, you think you'll be able to like, switch to whatever character you would like? lol y'know, like switch from Megaman x to Zero... or Sigma... or any other characters.. just a suggestion.
Title: Re: [0.4.5] Megaman X Editor (September/09/2009) [WITH SPRITE EDITOR!!!]
Post by: Vanya on September 11, 2009, 02:26:11 pm
That would require a massive amount of ASM hacking and is a project in and of itself.
Title: Re: [0.4.5] Megaman X Editor (September/09/2009) [WITH SPRITE EDITOR!!!]
Post by: DQ Chao284 on September 12, 2009, 07:57:15 am
That would require a massive amount of ASM hacking and is a project in and of itself.

Well I know along the lines of Lunar Compress it registers the graphics and font compression data to be LC_RLE 3, at least denotes it as that, and well supposely that could take awhile for the next release.
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: Xeeynamo on September 15, 2009, 09:32:34 am
Well, in the next release I want to do a lot of things on my editor ^^. The first of these is the sprite editor for ALL SNES ROM (like tile layer pro) and a special support of sprites and palettes for Megaman X2 and X3! I want to do it for example to take the sprites of X2 and import it on X1 ROM. I want to do a rewrite half of program (speed optimizations, source code most malleable and easy) and create a level viewer. I'm not a big programmator (I'm only a simple highschool student) and I don't know the asm of SNES, because this works are for me very hard and take me a while of time :-[

@Zero: I think that the editor isn't very hard to use xD. Switch the characters is VERY hard and I'm not able to do it >_<. Isn't simple because the game isn't programmed to support other characters (For example in MMX3 is very simple to switch X and Zero :P). MMX1 miss the movement of zero or sigma, the base sprites and commands like jump and dash and a lot of things which makes it almost impossible to make Zero or Sigma playable (This happens only in 2D games)

@DQ Chao284: When I've read your post I'm tried for the first time Lunar Compress, but it doesn't work on MMX :(
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: justin3009 on September 15, 2009, 11:30:52 am
The switch from X to Zero was something I've actually been trying to figure out in MMX.  Not like, actually coding in crap to load the characters, but just doing a basic sprite hack.  But you'd have to figure out how the sprites are assembled and what not in order for that to work fully.
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: Xeeynamo on September 18, 2009, 01:07:34 pm
I'm trying to do a Title Editor. The work is at beginning and for now there's the disadvantage that the tiles are loaded from png files (>_>). The work is veeeeery long, but a little funny ;D.

EDIT: I've complete the Level Viewer and Tiles Editor and I've all the offsets of all levels, but there is a big problem and I ask an help at the forum :). Every level have a scene (256x224 i think) and it's formed by 56 32x32 tiles. Every 32x32 tiles it's formed by 4 16x16 tiles and every 16x16 tiles (i think that) is formed to 4 8x8 tiles.
(http://img27.imageshack.us/img27/8516/immaginenxp.jpg)
Well, i know how the game create the scenes and the 32x32 tiles but I don't know how the game create 16x16 tiles from the 8x8 tiles >.<. How I can find the routine that create the 16x16 tiles?
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: Corvus on October 01, 2009, 08:35:51 pm
Progress?
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: Tallgeese on October 02, 2009, 01:24:31 am
Unless he's been helped over PM, he may be stalled.
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: acb on October 03, 2009, 02:39:23 am
I hope to see a level editor soon. Good luck!
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: smkd on October 03, 2009, 03:41:44 am
for about a week I was interested in hacking this game, I made a functional viewer that was not 100% but got bored with it pretty fast.  the source loads levels and graphics from ROM and shows a full level preview.  palettes were not loaded 100% correctly.  the source might help, I have no note documents or atleast any I can find.

http://smkdan.eludevisibility.org/other/MMX1.zip (http://smkdan.eludevisibility.org/other/MMX1.zip)
the bloated size is from the PNG files I never bothered to delete

all screens are 256x256 in size, you just can't see the bottom bits in the first level.

e: this may not help answer that last question much, but I found all the level data + pointers with gieger's snes9x and backtracking through the routines that put the 8x8 foregrounds tiles into vram.
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: Metal Knuckles on October 03, 2009, 09:42:56 pm
Some research into Megaman X hacking has been done over at the Sonic Retro forums, (http://forums.sonicretro.org/index.php?showtopic=11766&st=0) if it's any help. At the very least, you can PM some of the users for a bit of research they've done.
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: Lin on October 03, 2009, 09:56:39 pm
Wow! Finally, a Megaman X level editor is to come. I love the series and have always been wanting to edit them. I'd make the editor myself, but I don't know how data works... But I'm busy with another project right now, but good luck :)
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: Xeeynamo on October 04, 2009, 05:56:37 am
@smkdan:
IT'S FANTASTIC, THANKS!!!!! Today I will study your source code, and I hope that a full level editor will be release soon (:
One question: how I can find the pointers or the routines? I'm a beginner with Geiger's snes9x debugger >_<
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: azoreseuropa on October 05, 2009, 04:55:22 pm
Try this:

(http://www.romhacking.net/utils/screenshots/273screenshot1.png)

http://www.romhacking.net/utils/273/
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: smkd on October 06, 2009, 01:31:58 am
yeah go with bsnes unless gieger's has a feature you need that bsnes doesn't offer.  Would've used bsnes for its nifty vram breakpoints if it was around at the time I worked on that.  Pointers are in the code somewhere, map.cs I think.  At the top, it's 24bits per level.  Routines you can see by setting breakpoint on the pointers and look at how the code works with them.  It will load the level # from RAM and choose one of them.  The level RAM address will be handy for any other work you do so make a note of it.  VRAM breakpoint on foreground tiles will show you the code that uploads the 16x16 blocks and if you see where in RAM the 16x16 blocks are placed, then you can easily find the code that works with them.
Title: Re: [0.5.0] Megaman X Editor (September/12/2009) [WITH SPRITE EDITOR!!!]
Post by: Tater Bear on October 06, 2009, 10:56:37 pm
Some research into Megaman X hacking has been done over at the Sonic Retro forums, (http://forums.sonicretro.org/index.php?showtopic=11766&st=0) if it's any help. At the very least, you can PM some of the users for a bit of research they've done.
That is neat! I hope he puts the ability to use that unused enemy sprite, since the code appears to be there.
Title: Re: [0.6.0] Megaman X Editor (October/12/2009)
Post by: Xeeynamo on October 12, 2009, 12:24:34 pm
After a month, I've released the 0.6.0 version of Megaman X Editor ^^ the level editor is very slow and you can't edit 16x16 and 32x32 tiles. On the next release I will try to speedup the Level Editor and I will develope a Tiles Editor (It's easy to make). I want to say THANKS to smkdan for his sourcecode, that have help me on load of 8x8 tiles from vram and the arrangement of a level (I want to make also a complete Level Viewer). The link is placed on the first post!
Title: Re: [0.6.0] Megaman X Editor (October/12/2009)
Post by: MikeVincent on October 13, 2009, 03:55:58 pm
Hello
Iam Mike Vincent and maybe you've heard about my hack Mega Man Maverick Revenge? Well, iam very excited about this program and Iam looking forward to this alot. But Iam wondering due to my lack of skills in programming, will there be enemy edits available? And about tsa, is it possible to choose everything on them from background, foreground,  wall, water, bossdoor, spikes etc etc? And will palletes be editable? Maybe pallete effects? Well, Iam not sure if all this is even possible. I have no knowledge of Snesrom hacking.

But Iam wishing you all the luck with this gem and hope for some updates soon! =)

Greets from Mike
Title: Re: [0.6.0] Megaman X Editor (October/12/2009)
Post by: Xeeynamo on October 14, 2009, 10:18:40 am
Hello
Iam Mike Vincent and maybe you've heard about my hack Mega Man Maverick Revenge? Well, iam very excited about this program and Iam looking forward to this alot. But Iam wondering due to my lack of skills in programming, will there be enemy edits available? And about tsa, is it possible to choose everything on them from background, foreground,  wall, water, bossdoor, spikes etc etc? And will palletes be editable? Maybe pallete effects? Well, Iam not sure if all this is even possible. I have no knowledge of Snesrom hacking.

But Iam wishing you all the luck with this gem and hope for some updates soon! =)

Greets from Mike
Hi Mike :)
I want that my Megaman X Editor will be a full editor of this fantastic game, but now have only the basics that allow the hack of rom. Eheh, also I haven't a good knowledge of programming, infact the development of mmxe is a little slow... For the enemy editor you will wait, because now I want to develope the tiles editor and optimize the level editor (on sunday 0.6.1 version will be completed), after I want to add the level editing of all levels and after i will make an object editor (enemies, bosses, spikes etc). I think that after october, you will see an object editor ^^

October 17, 2009, 09:37:23 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
Well, I'm working on the support for the other levels on the game. Thanks to the source code of smkdan, I've used the RLE Decompressor for using the tiles of game without using vram states of the game :)
(http://img193.imageshack.us/img193/5153/immagineogi.th.png) (http://img193.imageshack.us/i/immagineogi.png/)
This is a screen of a prototype of the new version of mmxe! I hope that my works will be finished at soon ^^
Title: Re: [0.6.1] Megaman X Editor (October/18/2009)
Post by: MikeVincent on October 18, 2009, 11:53:55 am
The editor is getting better and better. If it's alright with you I have a few tips and things I(and probably others to) would like in this editor. Not that I doubt that you would make it good, but tips on the way is always helpful =). Alright, here goes -

It looks like Capcom uses a similar way to create levels in the SNES games as in the NES games. Well, in the level editor there is a tile window, a tsa window and a structure window. Is it possible to make the structure window bigger? Like in MegaFLE X if you tried it? And maybe in the tsa, a way for the user to choose the tsa settings? Like wall, spike etc? And in the tile window, a tile editor? That would be the ultimate. And about colours, would pallete animations be possible to do? And pallete colour changes and such. Also a title screen, weapon menu and level select screen editor in the window where you select the level you want to edit would be sweet =)
Well, I have no idea how hard these things is to make, and Iam sure you already have planned most of them =). I can't explain how thrilled iam about future realeses on this! Good luck to you!
/Mike
Title: Re: [0.6.1] Megaman X Editor (October/18/2009)
Post by: elixirnova on October 18, 2009, 08:50:27 pm
Very good looking. Definitely excited by all the progress you are making!

Not to gripe, but I never did like editing only a single screen at a time in the nes megaman editors, kinda hard to see the big picture of what your working on. I'm also liking the looks of the new features your adding to the level editor mode.

Keep it up! :cookie: :cookie:
Title: Re: [0.6.1] Megaman X Editor (October/18/2009)
Post by: justin3009 on October 19, 2009, 09:12:38 am
I don't know if this would be helpful in general for future hacking, but the SPC system is practically the same in every Megaman X game on the SNES.

http://www.youtube.com/watch?v=tACAbEwulCg - Tried swapping X3's music with X2's and thus the result of this.

Maybe useful for future Megaman X SPC hacking if it was delved into more.  Just thought I'd share a little results of some testing.

Edit: Appears that X1's is pretty different, so I guess maybe this'll be for X2/X3 :|
Title: Re: [0.6.1] Megaman X Editor (October/18/2009)
Post by: DQ Chao284 on October 19, 2009, 09:15:49 pm
I don't know if this would be helpful in general for future hacking, but the SPC system is practically the same in every Megaman X game on the SNES.

http://www.youtube.com/watch?v=tACAbEwulCg - Tried swapping X3's music with X2's and thus the result of this.

Maybe useful for future Megaman X SPC hacking if it was delved into more.  Just thought I'd share a little results of some testing.

Edit: Appears that X1's is pretty different, so I guess maybe this'll be for X2/X3 :|
Well that is due to all BG graphics in MM7 and X1 are in that RLE2(3 maybe?) compression, much harder than LZs 1 through 8, but it is good that the 8x8 tile editor is working since the unused characters are hidden in the compression.
Title: Re: [0.6.1] Megaman X Editor (October/18/2009)
Post by: Lin on October 19, 2009, 09:53:52 pm
Nice job on the level editor. But, as a .NET user myself, you must do everything you can to make the drawing as fast as possible. Never use the Set/GetPixel methods, but use unsafe or DMA code. There's many examples online, and ones that make it very easy (Look up FastPixel). Whenever you draw something (Like click on the map to set a block), don't set the data and redraw the whole map. Just set the needed data and just draw the single tile using the Graphics class.

By the way, did you set your forms' DoubleBuffered property to true? It really helps a lot with flickering.
Title: Re: [0.6.1] Megaman X Editor (October/18/2009)
Post by: Xeeynamo on October 20, 2009, 10:29:02 am
@MikeVincent: Thank you for regards! About the functionality for the editor program is not simple for me to create it. I have planned to finish the mean functions as level editor and object editor...after I will see for the rest! I don't know yet what you mean with tsa but if u want u can send me some screen of a preexisting editor. I can't use MegaFLE X because i have an Os of only 64 bit :(

@elixirnova: I didn't understand what you mean for editor multiwindow. I know that my level editor is a bit confused and very difficult but i accept every piece of advice u give me ^^ i wanna do better

@Lin: Alas the .Net is a bit slow and for this reason i think to convert it in C++,but i don't know how to program in win32. You'r right, when I modify Tiles i do wrong downloading the scene and i'll also work on. And not, I haven't set to true dthe Double Buffered :S
Title: Re: [0.6.1] Megaman X Editor (October/18/2009)
Post by: MikeVincent on October 20, 2009, 10:39:26 am
i understand if its not easy to make everything that people want but these tsa options iam gonna show you is realy kinda needed in a editor. however, i dont actualy know if mmx works the same way as mm3-6 so this can be done. but on this picture you will understand what can be done with tsa blocks in mega fle x.

http://acmlm.no-ip.org/uploader/get.php?id=2354
Title: Re: [0.6.1] Megaman X Editor (October/18/2009)
Post by: Xeeynamo on October 20, 2009, 11:32:24 am
i understand if its not easy to make everything that people want but these tsa options iam gonna show you is realy kinda needed in a editor. however, i dont actualy know if mmx works the same way as mm3-6 so this can be done. but on this picture you will understand what can be done with tsa blocks in mega fle x.

http://acmlm.no-ip.org/uploader/get.php?id=2354
Now I understand XD, the tsa determine if the 16x16 block is a wall, background etc and set the collision right? I don't know where this values are stored, but in next week i want to start to search them
Title: Re: [0.6.1] Megaman X Editor (October/18/2009)
Post by: MikeVincent on October 20, 2009, 11:36:27 am
yes thats what i mean :) it would also be nice to be able to choose witch pallete the 16x16 block should have. i understand if theres alot of work with the editor though, so i will wait as patience as i can =) good luck!
Title: Re: [0.6.1] Megaman X Editor (October/18/2009)
Post by: Xeeynamo on October 20, 2009, 02:18:47 pm
yes thats what i mean :) it would also be nice to be able to choose witch pallete the 16x16 block should have. i understand if theres alot of work with the editor though, so i will wait as patience as i can =) good luck!
I'm working on the possibility to switch the palettes on 16x16 tiles ;)
Never use the Set/GetPixel methods, but use unsafe or DMA code. There's many examples online, and ones that make it very easy (Look up FastPixel)
In 10 minutes I've studied the original sourcecode that I found searching with google and I've created a custom lib of fastpixel. Wow, I've see a big speedup on sprite editor, but the level editor continues to be slow )=...
This is the code, 500+% faster that the standard SetPixel http://digitalwork.altervista.org/digitalwork/files/download.php?file=fastbmp


October 21, 2009, 06:58:02 am - (Auto Merged - Double Posts are not allowed before 7 days.)
YES!!! Look here!!!
(http://img202.imageshack.us/img202/9543/newrendering.th.png) (http://img202.imageshack.us/i/newrendering.png/)
Now the only thing that it misses is the Tiles16 editor :)
Title: Re: [0.6.1] Megaman X Editor (October/18/2009)
Post by: MikeVincent on October 21, 2009, 11:02:56 am
looking good, very good! some kind of tile editor would be sweet as well, so you could import graphics from other games and/or paint your own custom tiles. Iam sure its on the way to =) Keep it up!
Title: Re: [0.6.5] Megaman X Editor (October/24/2009)
Post by: Xeeynamo on October 24, 2009, 03:14:26 am
New version released!
(http://img132.imageshack.us/img132/7086/065preview.th.png) (http://img132.imageshack.us/i/065preview.png/)
Title: Re: [0.6.5] Megaman X Editor (October/24/2009)
Post by: Corvus on October 24, 2009, 05:30:32 pm
The speed at which you have worked is incredible. I admire your dedication, and am watching your progress regularly.
Title: Re: [0.6.1] Megaman X Editor (October/18/2009)
Post by: elixirnova on October 30, 2009, 04:29:33 pm
@elixirnova: I didn't understand what you mean for editor multiwindow. I know that my level editor is a bit confused and very difficult but i accept every piece of advice u give me ^^ i wanna do better

I'll elaborate.

In this screen shot.
(http://img132.imageshack.us/img132/7086/065preview.png)
The "Scene" editor as you termed it which has Scene #xxx & Save Scene under it is what I am talking about.

I find it difficult to edit a scene when I do not know exactly how it fits in with the scenes to the left and right of it on the stage map (or on the top and bottom of that scene if it is a vertical scroll portion.

You could possibly load a scaled down snapshot of the entire stage and allow a user to click on the stage map and select which scene to edit. A snapshot of the stage would look something like this
(http://www.vgmaps.com/Atlas/SuperNES/MegaManX2-X-HunterBase-Stage2.png)

I can see this being useful when you can allow editing of sprites since scrolling actions are probably controlled via sprites. This could allow the user to make vertical scrolling areas in a once mostly horizontal level.

Does that make more sense?

By the way again impressed by the progress you keep making each week!
Title: Re: [0.6.6] Megaman X Editor (October/28/2009)
Post by: Xeeynamo on November 01, 2009, 03:09:33 am
I'm already working on a level viewer :) I don't release the new version because I want to able the editor to save an edited layout:
(http://img97.imageshack.us/img97/6471/mmxe070.th.jpg) (http://img97.imageshack.us/i/mmxe070.jpg/)
When you click on "Preview of the level" appear the window on left of the screen. On the hex editor you can see how the layout of the level is compress and I think that a layout editor will be very hard to develope :S. I want to merge the checkpoint editor with the layout editor and after develope an object editor!

Quote
I can see this being useful when you can allow editing of sprites since scrolling actions are probably controlled via sprites. This could allow the user to make vertical scrolling areas in a once mostly horizontal level.
I think that it's based on invisible objects placed on the level, but now the only mode to remove the limitation of the scrolling before touch this invisible object is the "border" of the checkpoint editor

November 02, 2009, 12:13:13 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
Released new version! ;)
Title: Re: [0.7.0] Megaman X Editor (November/02/2009)
Post by: EntraxZ on November 19, 2009, 12:30:21 pm
Hello! i am new here, and my english is very bad xD sorry .. but i have a problem with the editor ... i download it and open it and launch an error of megaman x editor has encountered a problem and needs to close , we are sorry for de invonvenience, ... and i dont know whats up with the program  :'(  .... help plz XD i need this...
Title: Re: [0.7.0] Megaman X Editor (November/02/2009)
Post by: MikeVincent on January 05, 2010, 01:20:28 pm
So.. is this project still alive? Sad thing if it aint  :-\
Title: Re: [0.7.0] Megaman X Editor (November/02/2009)
Post by: thebigstar on January 08, 2010, 09:35:40 am
So.. is this project still alive? Sad thing if it aint  :-\

I hope not, it's only been a couple months, he probably has to eat or work or something stupid like that :p.

I just found out about this and I'm completely hooked, can't wait to edit the game once the sprite/enemy editor is complete. Oooh this is exciting...

If it is dead, any chance I can have the source? :S
Title: Re: [0.7.0] Megaman X Editor (November/02/2009)
Post by: Xeeynamo on January 20, 2010, 06:22:37 am
So.. is this project still alive? Sad thing if it aint  :-\

I hope not, it's only been a couple months, he probably has to eat or work or something stupid like that :p.

I just found out about this and I'm completely hooked, can't wait to edit the game once the sprite/enemy editor is complete. Oooh this is exciting...

If it is dead, any chance I can have the source? :S
Eheh I'm not dead XD I've the school and a real life and a lot of my projects are suspended. Before to resume the MMXEditor project, I want to learn a little of DirectX (2D) to implement it on my editor and on a my future project ;)
Title: Re: [0.7.0] Megaman X Editor (November/02/2009)
Post by: insomniadmx on January 20, 2010, 04:51:00 pm
I've been doing a little research on Megaman X lately. I think it would be a good idea to share it with everyone in this thread.

I'm hosting some of the stuff that I've documented. I'll be sticking my stuff here (hosting is expensive so that site might not be up for long):
http://insom.15-bit.com/stuff/ (http://insom.15-bit.com/stuff/)

I'll also be sure to add things to the datacrystal wiki entry for the game as I go as well:
http://www.datacrystal.org/wiki/Megaman_X (http://www.datacrystal.org/wiki/Megaman_X)

I'm hosting a few more docs that I haven't added to datacrystal yet (if someone wants to do that, I'd be grateful). Those mostly describe things in RAM at the moment, but I'll be putting code/ROM related stuff up too. The format that I use for my docs was inspired by Kejardon to a great extent.

Megaman X's code is quite different from the other SNES games I've examined. They constantly change the direct page register and have M and X set most of the time. It seems that Capcom's programmers aimed for code density over most other things, since they avoided using absolute addressing modes a lot of the time by doing much of the memory access with direct page.

Capcom reused a lot of code for the three Megaman X games on the SNES, and though the routines that write X's graphics to VRAM are almost the same throughout, they are stored to and execute from bank $7E in the second two games, perhaps having something to do with the Cx4 chip. (I've read that the chip was used extensively for those games' graphics.)

Xeeynamo: I'd love to contribute something to this editor. If there's any aspect of the game that you would like to have me look into, tell me and hopefully I can get around to doing it.
Title: Re: [0.7.0] Megaman X Editor (November/02/2009)
Post by: Xeeynamo on January 22, 2010, 08:25:09 am
@insomniadmx:
Wow, I thank you for share these informations!!! I'm happy to have a little of help to this project :). I'm a beginner of assembly-programming and I'm searching someone that can help me. But before to release a new version of my editor I want to learn the DirectX's libs for a fast drawing of the sprite and tiles and remake all the editor for a comfortable GUI and various improves. (I'm afraid that in this post my english is veeeery poor XD)
Title: Re: [0.7.0] Megaman X Editor (November/02/2009)
Post by: insomniadmx on January 23, 2010, 12:29:05 pm
Don't worry, your english makes perfect sense.

Send me a private message if you ever have something you want help with.
Title: Re: [0.7.1] Megaman X Editor (January/24/2010)
Post by: Xeeynamo on January 24, 2010, 01:53:49 pm
I've released a new version, the 0.7.1. This build is very old, compiled on the first days of December. I haven't release it before because I've implemented a new function on Level Layout but it doesn't work very well.. If you want to try it you can download them on my website (look the first post). In this two days I'm developing a new GUI for Megaman X Editor (MDI Forms) and I'm rewriting all the core of the editor for more speed and malleability (support of MMX ROM that have the levels or the sprites located in a different place and eventually X2 and X3 roms). The work is hard and I ask you two (or most) week for redeveloping all
Title: Re: [0.7.1] Megaman X Editor (January/24/2010)
Post by: Zealous98 on January 24, 2010, 08:24:03 pm
Hi,

you said you moved the checkpoint editor into the level editor for v7.0. How do you access the checkpoint editor? The level editor didn't seem to change from 6.0. If it is a software issue on my computer, then can you make available version 6.0? I would prefer to use 6.x, personally. Thanks.
Title: Re: [0.7.1] Megaman X Editor (January/24/2010)
Post by: Xeeynamo on January 25, 2010, 11:44:47 am
Hi,

you said you moved the checkpoint editor into the level editor for v7.0. How do you access the checkpoint editor? The level editor didn't seem to change from 6.0. If it is a software issue on my computer, then can you make available version 6.0? I would prefer to use 6.x, personally. Thanks.
Try to move your rom in C:\ unit and rename it as lol.smc. It's an issuse of 0.7.0 version :S that I've correct on 0.7.1 version
Title: Re: [0.7.1] Megaman X Editor (January/24/2010)
Post by: Zealous98 on January 26, 2010, 01:42:02 am

Try to move your rom in C:\ unit and rename it as lol.smc. It's an issuse of 0.7.0 version :S that I've correct on 0.7.1 version

Moving the editing rom and renaming it does nothing. Also, sorry--I actually looked into 7.1 and I don't see any difference.

Could I use any 6.x version please?
Title: Re: [0.7.1] Megaman X Editor (January/24/2010)
Post by: Xeeynamo on January 26, 2010, 03:08:20 pm

Try to move your rom in C:\ unit and rename it as lol.smc. It's an issuse of 0.7.0 version :S that I've correct on 0.7.1 version

Moving the editing rom and renaming it does nothing. Also, sorry--I actually looked into 7.1 and I don't see any difference.

Could I use any 6.x version please?
I don't have 0.6.x version or older sorry =(. However I've uploaded a fixed version on my official website, try it. You can see the checksum editor in "level layout". Sorry for the mistake >.<
Title: Re: [0.7.1] Megaman X Editor (January/24/2010)
Post by: Zealous98 on January 26, 2010, 11:30:10 pm

I don't have 0.6.x version or older sorry =(. However I've uploaded a fixed version on my official website, try it. You can see the checksum editor in "level layout". Sorry for the mistake >.<


Ah! Okay, so the checkpoint editor was in the level layout editor. It just was not available yet.
Thanks very much! Now I can start my little project...
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: Xeeynamo on February 15, 2010, 06:40:47 am
In these days I'm learning the 65C816 assembly and I'm programming a little interpreter in C#. This will be a lot useful because if the pointers in the rom or the various algorithm will be changed, the editor will read with successful the rom. Try to image to move the layout of the levels in another location of the rom (for example in 0x180000 offset) and change the pointer that load the layouts: my editor will be read the levels on the new location! 6 months ago I was a bit n00b with the programming and Megaman X Editor was based on fixed addresses. Maybe I can say that my editor was only a proof of concept of a full Megaman X Editor. However with the new version of MMXEditor we could have support also for MMX2 and MMX3 (maybe also MM7 and Rockman & Bass if these are based on the same engine of MMX).
Stay tuned, new informations will be release soon ;)
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: justin3009 on February 15, 2010, 09:32:24 am
Wow..it's been 6 months already since you released this? Wow...Where has time gone.

Either way, I'm excited for this!  It's amazing :3
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: andrewclunn on February 15, 2010, 03:43:41 pm
Awesome.  I'm really looking forward to this.  (Maybe I'll be able to make a version of MMX 3 that I can beat without save states...)
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: slidelljohn on June 01, 2010, 10:31:47 pm
release the source we need to complete this  :banghead:
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: DarknessSavior on June 01, 2010, 11:21:45 pm
release the source we need to complete this  :banghead:
Calm down. Just because he hasn't posted about it since February doesn't mean the project is dead or he isn't working on it. Be patient and appreciative. Sheesh.

~DS
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: MikeVincent on June 04, 2010, 06:07:16 am
release the source we need to complete this  :banghead:
Calm down. Just because he hasn't posted about it since February doesn't mean the project is dead or he isn't working on it. Be patient and appreciative. Sheesh.

~DS

but he hasn't ben online since april... i think this one is kinda dead already. shame...
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: DarknessSavior on June 04, 2010, 02:09:33 pm
release the source we need to complete this  :banghead:
Calm down. Just because he hasn't posted about it since February doesn't mean the project is dead or he isn't working on it. Be patient and appreciative. Sheesh.

~DS

but he hasn't ben online since april... i think this one is kinda dead already. shame...
So what? Some people have lives outside of Romhacking. He could've gotten a promotion at work, or he might be having a hard time at school or something. Given the amount of progress he's made so far, saying that this project is "Dead" is stupid. He'll be back and he'll finish it. Just be patient.

~DS
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: za909 on June 07, 2010, 12:41:51 am
Yeah,this project is ultra cool anyways
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: Xeeynamo on June 07, 2010, 05:01:56 am
I'm not dead ;) I'm only busy. I had promise that a new Megaman X Editor will be released. The previous editor was written in C#, a language program that work over an virtual machine and this cause a bit slow programs based on it. I've decided to rewritten all the code in C++ and in last 3 weeks I'm studied the WinApi32. The result? I'm developing now an editor like before but is 800+% fastest than MMXE.
(http://img63.imageshack.us/img63/8189/immagineuql.png)
(http://img143.imageshack.us/img143/9405/immagine2sn.png)
Now I want to develope an tile editor (like sprite editor of MMXE) but I don't know how to create it  :-\ I can't zoom an image in a window. After I'll implement the reading of layout of the level, an map 16x16 and 32x32 editor and I want to resolve a damn bug that occur when I open 2 times the "open file" dialog
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: slidelljohn on June 07, 2010, 06:57:40 am
Your the best Xeeynamo. 8)
Thanks for the update and keep up the good work. :thumbsup:
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: za909 on June 07, 2010, 03:04:02 pm
It only needs one feature:
Enemy editor
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: Lin on June 09, 2010, 07:19:32 pm
Hmm... Well, you've managed to really improve the speed, but you can get it to be much faster. For one, you should make it load an entire tileset and store it in an image, including one with the numbers (But create this the first time a user checks the checkbox). Then, set your picturebox's image to that and there will be no lag or flicker. If tilesets are the same throughout rooms (And from my experience with MegaMan XTreme, they're not. Some tiles differ) then you can cache them all and just recall them later.
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: Xeeynamo on June 10, 2010, 03:45:16 pm
Hmm... Well, you've managed to really improve the speed, but you can get it to be much faster. For one, you should make it load an entire tileset and store it in an image, including one with the numbers (But create this the first time a user checks the checkbox). Then, set your picturebox's image to that and there will be no lag or flicker. If tilesets are the same throughout rooms (And from my experience with MegaMan XTreme, they're not. Some tiles differ) then you can cache them all and just recall them later.
Thanks for the advice but I'm using a different system. MegaED X decompress the tiles in a vram space and transform the colors to an x86 readable format storing them in a cache long 512 byte. After the editor take the sprite and render it with the palette selected and display the bitmap. Yes, your trick is for a quickly load but a set of 0x400 tiles in bitmap format stored in a image on ram? 0x400 * 8*8 * 4 * 8 (tiles * width * height * bpp * NofPalettes) is 2mb of ram. If you use 16bit depth you will use 1mb of ram. With my system you will use 512byte of cache for 16palettes and 32kb (0x400 * 8 * 8 / 2) for vram that will contain the tiles in 4bpp and in raw format. Maybe your trick is a bit more faster but use more ram and is less flessible.
Picturebox? There's a system that is more faster for display images and it's called BitBlt (I've learned it with C++ and WinApi) but is a bit harder to use it
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: godagarah on August 21, 2010, 09:57:49 pm
Any updates? Id like the features to move capsules and the hadouken capsule to not need to be activated in a special way!(http://www.romhacking.net/smf/Smileys/newyabb/crazy.gif)

EDIT: and to be able to keep the hadouken upgrade after it is collected through passwords and x2 and x3 support and the ability to keep the light armor and hadouken from x1 in x2 by using password from x1 and the ability to keep the Shouryuken upgrade after it is collected through passwords in x2 and the ability to keep the light armor and hadouken from x1 in x3 by using password from x1 and the ability to keep the max armor and Shouryuken from x2 in x3 by using password from x2 and the ability to keep the light armor and hadouken from x1 and the ability to keep the max armor and Shouryuken from x2 in x3 by using the complete mixed password and to be able to keep the hyper chip in x3 by using a password and the ability to select armors in x2 and x3 normal armor light armor in x1 with the addition of the max armor in x2 with the addition of the giga armor in x3 and cant collect armor unless normal!

wheeze....
..dies....
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: Jandazekon on August 22, 2010, 05:59:38 am
I would like to use graphics/sounds/musics from old megaman games.
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: Zealous98 on August 27, 2010, 05:17:23 pm
Dude, guys, he's not HACKING the game, he's making a hacking tool. Doing weird things like improving the password system is not part of the goal. And anyway, the editor can only interface with Megaman X. Its sequels will require a fresh approach. I wouldn't expect Xeeynamo to work on them anytime soon if he's not even satisfied with the first one.

Also, inputting graphics can be done with a program like TileLayerPro. It's a lot of work, but you don't need a multi-purpose editor to do it. In fact, the editor's functions, so far, don't accommodate that kind of project very well.
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: DarknessSavior on August 27, 2010, 08:02:22 pm
Dude, guys, he's not HACKING the game, he's making a hacking tool. Doing weird things like improving the password system is not part of the goal. And anyway, the editor can only interface with Megaman X. Its sequels will require a fresh approach. I wouldn't expect Xeeynamo to work on them anytime soon if he's not even satisfied with the first one.

Also, inputting graphics can be done with a program like TileLayerPro. It's a lot of work, but you don't need a multi-purpose editor to do it. In fact, the editor's functions, so far, don't accommodate that kind of project very well.
Actually, many of the things they did in X2 and X3 are the same as they were in X. The dialogue system, for instance. Almost-exactly (if not -exactly-) the same.

~DS
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: justin3009 on August 27, 2010, 09:01:07 pm
The biggest difference I've seen between X and X2 or X3 is the SPC Core.  It's slightly different too the point so you can't import music from the first game to the 2nd or 3rd.
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: Xeeynamo on September 23, 2010, 08:18:48 am
Any updates?
Yes, I've found background layout, collisions, dynamic layout and palettes (for example if you play to Chill Penguin and after Flame Mammoth, the lava if frozen etc..), I'm converting a lot of routines in Pseudo-C code and after in pure C code for the editor. I'm rewritting some parts of code like I/O system from the editor to SNES rom and other things to modulate the editor
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: justin3009 on September 23, 2010, 08:21:52 am
If we're allowed to edit the background layout in the future, might I suggest a feature like Temporal Flux's?

In that program Ctrl + 1 removed Layer 1 which in this case is the foreground.
Ctrl + 2 removed Layer 2 which I believe is the background in this case.  It'd make a little easier to see how each part is put together and probably a lot easier to edit.  Although this is just a suggestion.
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: Xeeynamo on September 23, 2010, 08:32:48 am
If we're allowed to edit the background layout in the future, might I suggest a feature like Temporal Flux's?

In that program Ctrl + 1 removed Layer 1 which in this case is the foreground.
Ctrl + 2 removed Layer 2 which I believe is the background in this case.  It'd make a little easier to see how each part is put together and probably a lot easier to edit.  Although this is just a suggestion.
Yes, it's a good idea :) I want to do also something similar that hide the front layer (like the street lamps on first stage) or back layer


September 28, 2010, 05:19:27 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
And this airship what is it? O_o I've screen that from the background of Launch Octopus stage

(http://img813.imageshack.us/img813/2150/immaginelw.png)
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: justin3009 on September 29, 2010, 08:21:00 am
O_o, that's really odd.  Don't you fight one of those things in Launch Octopus's stage?  I think you get blown up by some sort of Tornado generator in that stage and it pops you up to fight one of those.  Not sure why it'd be there but it's probably a placeholder to take take out later.
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: Jigglysaint on September 29, 2010, 01:18:10 pm
That does indeed look like the ship you find in the stage.  When you destroy it, it comes crashing down and reveals the path to the Heart Tank.  The game must be set to get tile information from that spot.
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: Xeeynamo on September 30, 2010, 09:27:57 am
That does indeed look like the ship you find in the stage.  When you destroy it, it comes crashing down and reveals the path to the Heart Tank.  The game must be set to get tile information from that spot.
Oh yeah, now I remember :P I don't play to MMX1 from months. I'm only playing to Highway stage and Sting Chameleon stage to do tests xD. However I'm writing on my blog news about MMX editor (and other stuff) here http://xeeynamo.blogspot.com. I can't update this post every small update that I do, I prefer to use this topic only to show new releases or to read/reply to the answers of users that use Megaman X Editor.
Title: Re: [0.7.1] Megaman X Editor (January/26/2010)
Post by: justin3009 on September 30, 2010, 10:10:42 am
I'll be sure to check that blog often to see the progress on this amazing piece of work!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Xeeynamo on October 03, 2010, 03:55:09 pm
Update the first post :)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on October 03, 2010, 10:56:29 pm
3 words.  I love you xD.  This is seriously making my week so much better already
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Vanya on October 12, 2010, 02:12:55 pm
Thought I should bring your attention to this:
http://www.themmnetwork.com/2010/10/11/hidden-level-editor-discovered-in-mega-man-xx3/ (http://www.themmnetwork.com/2010/10/11/hidden-level-editor-discovered-in-mega-man-xx3/)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Xeeynamo on October 30, 2010, 06:03:42 pm
Released :).

Changelog from the previous editor:
Spoiler:
Changelog from Megaman X Editor 0.7.1
 - Moved from C# to C++ rewriting the entire editor
 - .Net framework no longer required
 - Now the entire level can be viewed on main window
 - Palette, tileset, tile mapping, block and scene editor separated
 - Free dynamic palettes are now supported (press A or S)
 - Free dynamic tiles are supported (press Z or X)
 - Now the editor load the fontset from the game
 - Various infos about the level added
 - Added collision viewer
 - Now palette editor can tell you which are the offset that they come from
 - Tileset editor now tell you if the tile that you have select it's lock by ASM, is compress or uncompress
 - You able to edit and save compressed tiles
 - Now you can edit the collisions of Tile mappings
 - Background viewer implemented
 - Background editor implemented
 - High speed rendering implemented
 - The editor use a virtual space of tile mapping to speedup the level viewer
 - The editor save the current size and position of the window
 - ROM can test on an emulator pressing a single button on the editor
 - The editor now load last rom used (if you want)
 - The editor now load the last level loaded
 - Checkpoint editor removed
 - Checksum fixer removed
 - Offset converter removed
 - Sprite editor removed
 - Text editor removed
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: andrewclunn on November 01, 2010, 09:26:20 pm
 :crazy: :woot!:
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: MutantBuster on November 02, 2010, 10:51:37 am
Well now... will this change the world?
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: thebigstar on November 03, 2010, 03:43:40 am
Probably, it's pretty phallic in it's nature.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: zhade on February 28, 2011, 02:27:24 pm
Is there suport for enemies/objects placement ?? I really need to play some new levels of mmx(1,2 or 3) but never could find any level hacks :(
I was making my own some years ago (forX3) but never could find some data about "room order" and had problems figuring the "objects" data.th

but now this editor seems like a dream come true ;) only lacks the object editing so ppl can start to make great new levels !

btw if any of you guys have made a hack of X1,X2 or X3 with new levels (even if its only half a level) I wanna play it!!!!!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on November 30, 2011, 12:25:28 am
I really really hate to revive this from the dead, but I thought I'd ask this.

Has anyone been able to open up a MMX2 rom with his editor? :/  It says it supports MMX2 now but anytime I try opening any sort of MMX2 rom, it just pops up an error specifically stating that "It's not a Mega Man X1 Rom".  Has anyone else had this same problem at all?
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: shadow501 on January 10, 2015, 02:24:12 pm
Released :).

Changelog from the previous editor:
Spoiler:
Changelog from Megaman X Editor 0.7.1
 - Moved from C# to C++ rewriting the entire editor
 - .Net framework no longer required
 - Now the entire level can be viewed on main window
 - Palette, tileset, tile mapping, block and scene editor separated
 - Free dynamic palettes are now supported (press A or S)
 - Free dynamic tiles are supported (press Z or X)
 - Now the editor load the fontset from the game
 - Various infos about the level added
 - Added collision viewer
 - Now palette editor can tell you which are the offset that they come from
 - Tileset editor now tell you if the tile that you have select it's lock by ASM, is compress or uncompress
 - You able to edit and save compressed tiles
 - Now you can edit the collisions of Tile mappings
 - Background viewer implemented
 - Background editor implemented
 - High speed rendering implemented
 - The editor use a virtual space of tile mapping to speedup the level viewer
 - The editor save the current size and position of the window
 - ROM can test on an emulator pressing a single button on the editor
 - The editor now load last rom used (if you want)
 - The editor now load the last level loaded
 - Checkpoint editor removed
 - Checksum fixer removed
 - Offset converter removed
 - Sprite editor removed
 - Text editor removed


Well done and keep up bro  :happy: :thumbsup:
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on December 11, 2015, 08:11:57 pm
Luciano (ie Xeeynamo) has been kind enough to release the source code as freeware via github:

https://github.com/Xeeynamo/MegaEdX/ (https://github.com/Xeeynamo/MegaEdX/)

I've volunteered to help out with this project. I have no experience rom hacking, but I'm familiar with C++, assembly, and hexadecimal so reading some guides to get a better understanding of making this level editor work the best. I've talked to a few people and gotten SMILE so that may unlock the secrets to getting it work. I'm also looking a lunar magic as a comparison, but I haven't seen any location where they have source code available.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Seeeeph on January 06, 2016, 11:11:33 pm
.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: DackR on January 07, 2016, 11:25:06 am
Luciano (ie Xeeynamo) has been kind enough to release the source code as freeware via github:

https://github.com/Xeeynamo/MegaEdX/ (https://github.com/Xeeynamo/MegaEdX/)

I've volunteered to help out with this project. I have no experience rom hacking, but I'm familiar with C++, assembly, and hexadecimal so reading some guides to get a better understanding of making this level editor work the best. I've talked to a few people and gotten SMILE so that may unlock the secrets to getting it work. I'm also looking a lunar magic as a comparison, but I haven't seen any location where they have source code available.
This is awesome news! I asked Xeeynamo about the source code sometime in March 2015 and he said he intended to release it after he finished a few things. Freaking awesome that it's out there now!

This is interesting.

I think this game may be my next venture once I quit Zelda 3.

Already started an hack of MMX-1 and worked on and off for the past three years but don't know if there is still an interest in that game to continue working on it.
The first MMX is special to me because it was the first in the series that I played through to the end. I'm sure I'd play your hack if you released it, considering the apparent quality of your other work.

Side note: I made a story skip patch for MMX and RMX a couple years ago with the intention of using it for unofficial speed runs. I'll have to try out this tool and see what else is possible... :beer:
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on February 19, 2016, 11:27:37 pm
Someone pointed me at the source for this editor a few weeks ago after I offered some C++ help.  I now have a local copy of the editor with the following changes:

- X2 and X3 support
- Event editor
- Minor tweaks to make the Scene and other editors easier to use
- A really basic (hack) Sprite editor (displays a fixed region of memory as 4bpp graphic tiles)

There's also code to resort the tiles for better compression, but it's not very smart or well tested.  This makes it easier to edit tiles and have them fit into the same space as the original compressed region.

This is the first time I've done windows gui programming or any rom hacking (snes or otherwise) so some of the changes are not clean.  The editor also has some things that could be improved that I haven't touched.  E.g. losing edits if the level is changed without saving.  The code could use some cleanup if I were to share it so I wanted to see if it's useful to anyone.  I need to learn how to use git, too.  Let me know if there is any interest in this.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: DackR on February 19, 2016, 11:39:57 pm
Someone pointed me at the source for this editor a few weeks ago after I offered some C++ help.  I now have a local copy of the editor with the following changes:

- X2 and X3 support
- Event editor
- Minor tweaks to make the Scene and other editors easier to use
- A really basic (hack) Sprite editor (displays a fixed region of memory as 4bpp graphic tiles)

There's also code to resort the tiles for better compression, but it's not very smart or well tested.  This makes it easier to edit tiles and have them fit into the same space as the original compressed region.

This is the first time I've done windows gui programming or any rom hacking (snes or otherwise) so some of the changes are not clean.  The editor also has some things that could be improved that I haven't touched.  E.g. losing edits if the level is changed without saving.  The code could use some cleanup if I were to share it so I wanted to see if it's useful to anyone.  I need to learn how to use git, too.  Let me know if there is any interest in this.

Dude. No question this would be helpful for people. Put it on github so we can fork it! :)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on February 20, 2016, 11:18:25 am
SERRIOOUUSSLLLY have interest in this!  I'm no C# or C++ coder sadly, I only have a few broad understanding of it, but if you need anything X2/X3 ASM wise I'm more than glad to help with it.  Especially with Sprite Editing, Sprite Assembly and Animation Data as well.  I've messed with enough of that to have a decent understanding of it.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on February 20, 2016, 06:11:45 pm
For those of you who have visual studio or want to look at the source here's a github link: https://github.com/RedGuyyyy/MegaEdX.git

And for those who want to try a precompiled version: https://drive.google.com/file/d/0Bx9gzQZCkH8qSy0tVGRDN2JHYzQ/view?usp=sharing

The precompiled binary is just temporary until I figure out if/how it should be distributed.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Seeeeph on February 25, 2016, 06:14:42 pm
.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on February 25, 2016, 11:58:31 pm
Glad to hear people are finding the editor updates useful.

I updated the source with an enemy property editor that supports editing HP and the Damage Modifier for some enemies.  You need to know the enemy ID to edit the right one.  It's a bit of a hack because in X1 and X2 the values are constants in LDA instructions.  So the editor tries to walk through and find the right STAs and the preceding LDA.  It has a dumb pattern matcher so it's possible (though unlikely) it will think it found a value when it's actually some other part of memory.  It may or may not work for bosses assuming it can actually find their HP and Damage modifier.  The damage modifier is shared across a lot of enemies so changing one will change other enemies.  HP seems unique, though.  X3 has a table in rom with the values which is a lot easier to work with.

Here's a compiled version: https://drive.google.com/file/d/0Bx9gzQZCkH8qT0d1TkRZMERiOFE/view?usp=sharing
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on February 26, 2016, 08:14:56 am
Might be a good idea in the long run to possibly have every enemy have their own damage values, if not that, maybe allow for adding a new feature in the editor where you can dictate which enemy shares what damage table with the others but you have the option of creating a new one.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Seeeeph on February 26, 2016, 09:30:49 am
.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on February 26, 2016, 09:59:02 am
Are you referring to the scene editor?  That's already changed to:

- Include a scene window, block window, and selected/replaced window.
- Right mouse selects a block in any of the following windows: scene, block, replaced.  The block window goes to the selected block.  The selected window changes to a picture of the block.
- Left mouse replaces the block under the cursor in the scene window.  The replaced window changes to a picture of the replaced block (only if the block number changed).
- There are focus rectangles help identify the block in the scene and block window.

It's a big hack right now, but there are also changes to allow typing new hex values in the other editors which have spinboxes.  The previous version of the editor wouldn't record changes that were typed in.

I'll take a look at separating the hp and damage values in X1 and X2 into a table like X3.  That would make editing them a lot easier and eliminate the cases where enemies share the same value.

Here's a picture of the scene editor.

(https://lh3.googleusercontent.com/-9o9QhulbEXU/VtBqmPRPtpI/AAAAAAAAC5U/nXMkFSd-h9I/s682-Ic42/scene_editor.png)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Seeeeph on February 26, 2016, 11:16:43 am
.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on February 29, 2016, 12:22:24 pm
I updated the source to try to decompress the graphics for sprites.  It mostly works, but there are a few sprites that might not be compressed.  Also, the palette selection is kind of annoying right now.  I still need to find where the assembly information is... hopefully that has the palette reference.

The editing feature is disabled as modifying compressed data can lead to a larger compressed block which might overwrite other data.  That is solved with background tiles by hardcoding the original size for each level in the editor to check for a larger compressed block and sorting to improve compression.  This is a lot more work to do for 100+ compressed regions and I haven't found the sprite assembly information to fix the pointers if tiles are resorted.

The sprite editor is likely to remain a sprite viewer for a while.  I'm trying to get a fully assembled frame of the enemy with the correct palette to appear on the level when an enemy event is selected in the event editor.

Here's a binary: https://drive.google.com/file/d/0Bx9gzQZCkH8qZEtJVE5lTFd0VUE/view?usp=sharing
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on February 29, 2016, 01:30:31 pm
If you need help locating anything, just say the word and I'll do what I can to find whatever information you need.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Seeeeph on February 29, 2016, 02:15:59 pm
.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 01, 2016, 10:54:07 am
I was able to get 90% of a gun volt to load on the map when its event is selected.  In the picture below you can see I'm missing the pieces that change.  They are propably in a separate map.  I need to locate the other sprite assembly pointers to fill in the missing pieces, load the correct palette, and get the other enemies working.  It helped to read about VRAM, OAM, and sprite assembly in order to figure it out.  After that the traces and RAM dumps started making sense.  The info in the mmx 1-3 thread from justin3009 also helped to understand how sprites work.  Thanks for that.

Thanks for the info, Seeeeph.  I thought the events of type=2 (1=background sprite?, 3=enemy) did the graphics loading, but it looks like the checkpoint structure is also important.  I'll take a look at it when I have more time.

(https://lh3.googleusercontent.com/-FGMimRIiJ7s/VtW6ccR48aI/AAAAAAAAC5o/wbHcxbB-Tms/s798-Ic42/gun_volt.png)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on March 01, 2016, 12:14:00 pm
Glad to see this is being worked on again. I have a lot of the level data figured out and documented for v1.1 ROM. Here is a little bit of code that might help you out with the sprites graphics and color palettes. I have a bunch of documents i can send you that would save you a lot of time if you are interested in them just pm me your email and next time i get a chance I will send them to you.

/*part of level data of 1st level when you start a new game*/
$85:8302                  02      type of event                02 = graphics and color palettes
$85:8303-$85:8304 80 01 X location
$85:8305                 15      ???
$85:8306                  11     graphics and color palettes  stored at 7e:1d20
$85:8307-$85:8308 C0 81 Y location                   


/*where level data for graphics and color palettes for enemies, cars... are stored in ram*/
7e:1d10-7e:1d15                                //??? maybe here too not sure
7e:1d20-7e:1d25 80 01 15 11 16 FA             
7e:1d30-7e:1d35
7e:1d40-7e:1d45
7e:1d50-7e:1d55


/*step 1 of asm code for loading new vram for enemies, cars, .....*/
$83/FE0C E2 30       SEP #$30                 
$83/FE0E A5 0B       LDA $0B    [$00:1D23]       //$7e:1d23
$83/FE10 29 0F       AND #$0F               
$83/FE12 8D 08 1F    STA $1F08  [$86:1F08]    //$7e:1F08 graphics palette pointer


/*step 2 of asm code for loading new vram for enemies, cars, .....*/
$80/B09D AD 08 1F    LDA $1F08  [$86:1F08]   
$80/B0A0 29 FF 00    AND #$00FF               
$80/B0A3 0A             ASL A                   
$80/B0A4 85 00        STA $00    [$00:0000]   
$80/B0A6 AD 7A 1F    LDA $1F7A  [$86:1F7A]     //$7e:1F7a current level
$80/B0A9 29 FF 00    AND #$00FF
$80/B0AC 0A             ASL A                   
$80/B0AD AA             TAX                     
$80/B0AE BD EE AC    LDA $ACEE,x[$86:ACEE]     //$86:ACEE start of data for each level
$80/B0B1 18            CLC                     
$80/B0B2 65 00       ADC $00    [$00:0000]   
$80/B0B4 AA            TAX                     
$80/B0B5 BD EE AC    LDA $ACEE,x[$86:AD36]     //pointer to graphics and color palettes
$80/B0B8 AA             TAX                     
$80/B0B9 E2 20        SEP #$20                 
$80/B0BB BD EE AC    LDA $ACEE,x[$86:B647]     //graphics and color palettes
$80/B0BE C9 FF         CMP #$FF                A:0939 X:0959 Y:0000 D:0000 DB:86


/*data to load for graphics and color palettes for enemies, cars... (1st set 1st level)*/
86:b647-86:b65f
39 C0 14 9C 00 50
3A C0 17
9E 00 60
3B C0 1B C0 00 70
1F 00 10 3E 00 40 FF //FF = end of data to load
 |         |   |
 |         |    --------color palette
 |          -----------location in vram to store graphics
  -------------------graphics (1F = spiky)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Seeeeph on March 01, 2016, 01:53:18 pm
.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on March 01, 2016, 05:53:20 pm
The enemies and such, if I remember correctly, are all preset for the level.  They're not all loaded at the same time but the specific VRAM setup is level specific.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 02, 2016, 01:08:36 am
Looks like I wasn't loading the 16x16 sprites correctly.  That fixed some of the bugs with gun volt.  I must also not be ordering the tiles properly because it isn't layered quite right.  I can't find a good way to go from an enemy Id to an offset into the graphics data in the ROM to load the tiles.  Right now the gun volt offset is hardcoded to match with the gun volt Id.  The best way to do this is probably maintain VRAM by reading the checkpoint and walking through all graphics loading events up to the enemy displayed.  Then I can use the VRAM address stored with the sprite assembly to read the tiles directly.

Anyone know how the priority works for each sprite tile so they are layered properly?

Seeeeph, that mario level is pretty cool.  You can probably fix that (fish thing?) enemy graphics by adding in the all the events of type 2 before which might load it to VRAM from the original stage.

slidelljohn, I'll send you a PM.  Thanks.

(https://lh3.googleusercontent.com/-ic-kTl26aVo/VtZXMHpMgJI/AAAAAAAAC58/eC6j_3nUKI0/s612-Ic42/gun_volt.png)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on March 02, 2016, 02:47:41 am
This shows you where the priority bit is.
http://emu-docs.org/Super%20NES/General/snesdoc.html

I'm curious do you have vsnes? If not you should get
it because it will help you out a lot with building your
sprites and setting the bits for priority, color palette,
flipping. If you don't have vsnes I can show you how
to use it if you can't figure it out.

Also if the first and second tile in oam ram have the
same priority bit set the first tile will have priority over
the second tile. You could try drawing the last tile for
each sprite first and the first tile last and that will
probably solve your priority issue.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on March 02, 2016, 06:19:52 am
Sprite tile priority is based on which tile is technically drawn first for them through their Sprite Assembly.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 02, 2016, 01:53:40 pm
I'll take a look at vsnes.

The rotating priority was the problem. I reversed the order of tiles. Now I need to add transparency and load the right palette. Then I can move on to maintaining all of VRAM so I can draw any enemy whose tiles have been loaded properly.

March 02, 2016, 11:50:26 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
Ok.  Got it working for 8x8 (small) and 16x16 (large) tiles.  It has a few hacks in the code which aren't very pretty .  I'll take a look at the VRAM loading now.  I'm thinking of scanning all events up to the current one and loading up the VRAM.  Then I can display it in the event editor so you can double check what graphics are loaded and also makes it straightforward to display the enemy sprite at the current event.

(https://lh3.googleusercontent.com/-rtUVwNcA2oY/VtfB6WeoaZI/AAAAAAAAC6U/IzlklY3NuQI/s606-Ic42/gun_volt.png)

(https://lh3.googleusercontent.com/-ORlBe_23KJI/VtfB6ZZlGaI/AAAAAAAAC6Q/rxJBfc9yHow/s628-Ic42/spikey.png)

March 06, 2016, 11:33:38 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
I took a break from adding the VRAM tracking code and enemy display to support camera lock editing.  There are events (type=0x2, id=0x0) that trigger camera locks in 1 or more of the 4 directions.  The event editor can now be set to move between only camera lock events with a checkbox.  Events that trigger locks display a green bounding box that the engine checks when you enter it updates the bound to the direction and distance of the yellow line(s).  There are sometimes more than one direction per trigger event.  These types of events are often in pairs (or more) because you need to support the change in bounds when you are going in the reverse direction of the level (first event) and when you are going in the normal direction of the level (second event).  There's not a great way to add extra locks, but you can move the existing ones around and edit the directions and bounds.

Source updated.  Here's a binary: https://drive.google.com/file/d/0Bx9gzQZCkH8qdkR6bUZKRVhYRk0/view?usp=sharing

Here's an example from Kuwanger's stage where it changes (restricts) the bottom bounds after you climb up the ladder and opens up the right section.

(https://lh3.googleusercontent.com/-WXy2xFHgUoQ/Vt0D63JiM_I/AAAAAAAAC6w/1Q5Wyn7YE4U/s1024-Ic42/camera_lock.png)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Sting_Chameleon on March 07, 2016, 01:39:16 am
Very glad to see how far the emulator is coming along! I do however have two suggestions that seems to be an issue(both minor and not program breaking, but somewhat itchy in a way). I also have two suggestions that aren't bugs in the program, but something that would be nice to see changed.

Bugs I noticed:

1. On start-up, there is an invalid path error. I think it's the first time loading as well, as it'll close itself then re-open with the same error(only once though). Any further openings will result in the error message again, but the program stays open. It seems to be linked to the checkbox under File > Settings.
2. Under File > Settings, I'm unable to specify a path to my emulator.

Ideas I had in mind(seems like minor bugs too... ah well. shrugs):

1. When editing the tile properties, or at least viewing them on the main screen, it's difficult to read the numbers written on each tile. I mistake d for 0 and b for 8 quite often.
2. When editing scenes, the program doesn't update the map until the ROM saves or when a different level is switched to and return to the stage modified.

Aside from the two issues and the two suggestions, I've been enjoying the updated utility! I'm not sure how I can tribute/assist aside from spotting bugs I find(I'm not a strong programmer, but if there's basic hex tweak modifications needed as far as locations go, I can help there).

Also, if I may ask, what all is on the list of things to do for the utility as of now? Or is that a surprise in the future?  ;)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 07, 2016, 12:59:50 pm
I'll try to fix the settings menu if it's easy.  If not, I'll likely disable it along with the associated code to get rid of the error.  It doesn't look complete.

I can take a look at making the text more legible on the main screen.  It uses the font from the game.  There are quite a few bugs where changes are lost if you don't save.  E.g. most changes to tile graphics are lost if the level is changed.  Some of these bugs were introduced by me and some were there before my modifications.

It should be easy to have scene changes get reflected immediately in the main screen.

My goal was to help the person who originally asked for X2 and X3 support, event editing, and camera lock editing.  They are satisfied with the current version barring any bugs or new ideas they may have.  I don't have a formal list of future work, although, I'm interested in getting the enemy and object sprites to be visible for more IDs.  My gui programming skills and the editor could use a lot of help here.  That's why the new things are red, green, and yellow rectangles.  Those are easy to draw.  :)

Features will be mostly a surprise, but everyone is welcome to make suggestions and point out bugs.

March 07, 2016, 11:25:40 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
Fixed edits in the scene editor to now show up in the main map view.
Fixed fonts so they use the correct base font palette.
Fixed possible read of uninitialized settings variable.

The font is a little easier to see now.  Not sure if that helps, but at least it looks nicer.  X3 was using a random piece of memory as a palette before.  The settings seem broken on my machine (ini file never gets created) but other people aren't having a problem.  Eventually they should be updated to use the registry and not a ini file.

https://drive.google.com/file/d/0Bx9gzQZCkH8qQXJuald0RnRlOHM/view?usp=sharing

March 09, 2016, 12:30:52 am - (Auto Merged - Double Posts are not allowed before 7 days.)
See if the collision font is better in this version: https://drive.google.com/file/d/0Bx9gzQZCkH8qSFdfVUVwVmdUQnc/view?usp=sharing
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Bahamut ZERO on March 09, 2016, 06:59:55 pm
I know what I'll be playing around with the next time I'm burned out on the project I'm doing.  :D

Keep up the amazing work.  :)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Sting_Chameleon on March 10, 2016, 12:00:00 am
I jumped on to try the latest fix a little while ago.

I'm loving the newly updated font for each tile type. This makes it perfectly eligible without using a magnifier program and comparing pixels. No more problems with the aforementioned fixes. The scene editor now updates smoothly(even if it's not immediate on the main map, it still updates before closing the scene editor. :thumbsup: ) Though more ideas flow through my head. Here's more from me.  ;D


Some more ideas and requests:

1. The ability to select a path for the SNES emulator for tests.
2. As much as I want #1 implemented, I'd much rather be able to modify the sprites and other enemies with less of a hassle.
3. Also, what I'm curious about is why/when does the tileset change with enemies and boss rooms? Is it special events? If so, that needs to be labeled when going through event editor mode[1]. I know there's some way this is modified that doesn't seem easily legible in the editor, or I must be incredibly blind when I scan through the functions.
4. The icons at the top would be needed to be changed to make things easier to register when going through them. I can spend a few hours when I get up to make a few images to fit the buttons more easily that fits the style of the editor, giving it a unique and less boring feeling while editing[2].

[1]So maybe in standard font... "GFX CHANGE" or "TILESET CHANGE" then the tileset/gfx offset which the changes are made. If you want an image for this, I'll do my best to provide.
[2]If you can give me a recommendation on the pixel dimensions(or at least a max and min size to work with), I can try to work out what I can. Also I would need to know what format to use. JPEG/PNG/BMP, ect.

This is pretty much what came to mind when I saw the editor. Also be warned, my paint skills are no better than programming a line draw in an application. But I make do with what I'm capable of. :)

Here's 100k  :cookie:  for your hard work so far! Share to your contributors(exclude me, haha)!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 10, 2016, 12:55:35 pm
The settings need an overhaul which includes specifying an emulator.  Not sure if/when I'll get to this.  I'm sure basic management of the registry for settings is not hard, but I've never done it before.

Modifying sprites is interesting, but lower priority to other things.  Before a real editor can even be considered I need to first better understand the snes code which moves things into VRAM.

My basic understanding of it is checkpoints load a base set of tiles, objects, and palettes into VRAM along with a bunch of other things.  There is a checkpoint at the start of the level.  Events (notation is type, id, subid) can advance the checkpoint.  There are also events that can advance the tiles, objects, and/or palettes (individually?).  Typically these replace a small section of VRAM.  For example, in mmx1 on the highway stage the spikey tiles are loaded into VRAM with the first checkpoint along with cars that go by.  Then there is an event ($2,$15) before the gun volt that loads the gun volt tiles into VRAM.  If I remember right, it replaces some of the car tiles.  Some of the sprite tiles are compressed with either a simple MFU byte encoding (X1) or LZSS (X2/X3).  Some are not compressed.  X character tiles are generally not compressed - I assume because there are so many of them so it's better to just go to ROM and read it than using a lot of RAM all the time or frequently decompressing it (slow).  Enemies are generally compressed, but the big X2 intro stage boss is not.  Presumably for the same reason as X character tiles.

Ideally, the editor would identify what each event does, but I haven't had to time to work through instruction traces and make a list.  Type 0=?  1=random (non-interactive?) sprites like cars, etc 2=checkpoint loads, tile/object/palette loads, camera locks, etc 3=enemies including interactive sprites like elevators.  2,0,X is camera lock changes.  2,B,X and 2,2,X looks like checkpoint changes, but not sure on this.

The code is a bit of a mess right now as everything being added is experimental and poorly commented.  Most of the main view's drawing code is in MegaEdX.cpp (see WM_PAINT:)

I appreciate the offer for making new icons, but the editor is in too much a state of flux right now to spend time making it look better.  I'd hate for you to spend time making graphics that end up not being used because major things change.  For example, we may find that the current event and checkpoint editor should be combined making one less editor (and one less button).
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Bahamut ZERO on March 11, 2016, 06:28:18 pm
For what it's worth, I'm 90% sure the compressed graphics for Megaman X can be decompressed using Lunar Compress.


Not entirely sure if Megaman X 2 and 3's compressed graphics can be decompressed with the program, but I know I saw Megaman X 1 listed as one of the games it could decompress graphics for back when I was editing graphics in Star Fox.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: DarkSamus993 on March 11, 2016, 08:46:06 pm
Lunar Compress can indeed decompress Mega Man X1 graphics, not X2 or X3 (though X3 does have this tool (http://www.romhacking.net/utilities/552/)).
The command format is:  "FileToDecompress FileToSaveAs OffsetToStart(h) Format Format2"

My old documentation I made while using the program shows the compressed graphics start at 0xD0200 (headered ROM) and the program itself will only decompress 10000 bytes max at a time (if you use 0 for Format2).
So something like this: "MMX.smc MMX.bin D0200 102 0" will decompress 10000 bytes starting from ROM address 0xD0200.

Side note: the Lunar Compress DLL source code itself is not provided (where the actual decompression routines are programmed). What is provided however is the source code to help build your own application that uses the Lunar DLL.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 11, 2016, 09:16:42 pm
Thanks for the info about Lunar Compress.  The mmx editor already had X1 compression/decompression support before I worked on it.  I added code for X2 and X3 compression and decompression (LZSS) support in order to load and save tile graphics in those roms.  So I think we have all three games covered when it comes to compression and decompression.

March 14, 2016, 12:48:51 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
Small update.

I have most of the X1 enemies displayed when using the event editor.  The palette isn't always right, but it's still recognizable so I'm going to get the other sprites (misc objects like heart tanks and background cars) working.  Then I'll do the same for X2 and X3.

I also changed the sprite editor so it loads up the current enemy/object sprites into a window so you can see what tiles are available.  Ideally, this would be synchronized in some way with the event editor.  At one point I was using the sprite editor as a VRAM source for the event editor, but it seemed painful to have to update that view every time you move past a 2,15,x event just to see what enemy is.  It seems better to allow the user to place enemies wherever they want with some feedback on the current graphics loaded and then they can later modify what graphics get loaded so enemies show up properly.

2,x,x events are understood a little better now in how they trigger and change sprites, level tiles, and palettes.  There are also a lot of custom 2,x,x events that do things like spawn multiple enemies (e.g. jamingers, dragons) or multiple objects (moving platforms in X1 Eagle), create explosion effects, and other stuff.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Sting_Chameleon on March 14, 2016, 09:58:33 pm
This is a speculation on my part, but is the Dr. White capsule types hardcoded to the stage value, or is it hardcoded to asm? I know the check for MMX's equipment starts before the level loads to figure out if he has the upgrade or not, and a second time when MMX gets close to the capsule itself before it loads. I've done numerous tests and I'm not sure what the upgrade capsules look at when giving MMX the proper upgrade.

Also I did revert back to the previous editor. As a bug update, after the first few openings of the last published editor, the editor doesn't open any further than after 1 or 2 openings. My cursor still stays in the 'loading' icon state, and 3 processes are still open under task manager, and force closing them from there has no effect. But this is after the first opening.

EDIT: The above persists indefinitely or until logging off a user, not just restarting the computer.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 16, 2016, 09:14:42 am
The code uses the level number as an offset into 86:D362 to load another byte sized offset into 86:D3D5 to figure out which bits to set in 7E:1F99 which stores the upgrades X has.  Chill Penguin is level 8 which reads 86:D362+8 and gets the value 3.  Then it reads 86:D3D5+3 and gets the value 8.  8 is then set in 7E:1F99 to give X dash.

Sounds like there is some uninitialized variable problem with the settings it is trying to load when it opens.  If I have some time this weekend I'll look at it.

March 20, 2016, 12:54:06 am - (Auto Merged - Double Posts are not allowed before 7 days.)
https://drive.google.com/file/d/0Bx9gzQZCkH8qb3lnUk1VS1BoSjQ/view?usp=sharing

I changed the settings over to use the registry.  The load last rom at startup value wasn't initialized and hopefully was the cause of the loading problems.  I didn't setup an emulator to use, yet.

I hacked around on the sprite code and got most (~80%) of the enemy sprites to show up correctly.  A lot of objects have custom memory locations, hard coded LDA constants to get the graphics pointer for decompression or sprite assembly, and custom palette locations.  I didn't spend much time on those.  The sprites work in X1-X3.
- You can hit 'T' now to toggle on all enemy sprite display in the level.
- Going through the event editor will show sprites, if possible, on enemy types.
- If you go to a 2,15,x which is a sprite load (or 2,18,x) event it also displays all enemies in the level, draws a green box around ones whose graphics load in the forward direction of the event, a blue box on the reverse direction, and red box for ones that aren't loaded.
- Also on the 2,15,x there's a graphics loading dialog where you can scroll through the sprites that get loaded and modify them.  This allows you to remove or change the sprites that get loaded by these events to add enemy graphics that didn't exist before.  There's a window that attempts to display a sprite of what is loaded by one of the indices in the event.  If you change the sprite tiles that are loaded the palette won't refresh until add an enemy of that type in the level and you save/reload the level.  This code is a mess right now so I didn't spend a lot of time making it work right.

I was able to add an enemy from a different level in by adding the enemy event after a 2,15,x event and then editing the 2,15,x event to swap in the correct graphics and palette.  Make sure you use an unused palette slot if you play with this.  I think the VRAM Offset is also really a slot in VRAM to load the graphics and not the actual address, but I haven't looked at it close enough to be sure.

This all very experimental (and messy code) so don't count on it staying in this format or working properly.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Jigglysaint on March 22, 2016, 12:00:30 pm
This is a speculation on my part, but is the Dr. White capsule types hardcoded to the stage value, or is it hardcoded to asm? I know the check for MMX's equipment starts before the level loads to figure out if he has the upgrade or not, and a second time when MMX gets close to the capsule itself before it loads. I've done numerous tests and I'm not sure what the upgrade capsules look at when giving MMX the proper upgrade.

Also I did revert back to the previous editor. As a bug update, after the first few openings of the last published editor, the editor doesn't open any further than after 1 or 2 openings. My cursor still stays in the 'loading' icon state, and 3 processes are still open under task manager, and force closing them from there has no effect. But this is after the first opening.

EDIT: The above persists indefinitely or until logging off a user, not just restarting the computer.

From what I've seen with Mega man X3, and I assume the other two, is that the in level sprite is more of an initializing sprite.  The capsule location and the camera fix are both located elsewhere.  I have the data for X3, but it's been a long time since I've played with the data so I will have to re-learn it's format.

Edit:  I have rom locations, all are for an unheadered rom, and all for Megaman X3.

0x34CC2:  Capsule location inside level.  It requires the Capsule initialization event to be activated.  4 bytes each.  First 2 are on screen x co-ordinate followed by level position's x.  Next 2 are for the Y co-ordinate.

0x34CFA:  Capsule contents.  Values from 00 to 08 are valid.  00 to 03 are for the X armor, and 04-07 is for the chip enhancements.  08 is for the gold armor.

0x34D9F:  Capsule camera data.  Same as the capsule location except it only uses the level position bytes.  This triggers when you walk up to the capsule.  Without this value, the capsule cannot be moved or else mega man will scroll through walls and die.

0x9C5C6:  Capsule script pointers.  This is also important to moving the capsules, as it controls what Mega Man does after you obtain the upgrade.  Some are easy, such as armor, but others such as the air dashing need enough space to run the script or the game will soft lock.

That is all I've got on that.  I am assuming that X1 and X2 are similar.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 24, 2016, 12:10:50 am
I'm having a hard time getting all of the X3 boss sprites assembled correctly.  Namely Buffalo, Catfish, Tiger, Seahorse, and CrawFish.  I spent some time looking at Buffalo and I can see the pointer to ROM with assembly information being copied to the Cx4 chip.  It's the same address I use to get the assembly information.  Decompressing the graphics definitely shows Buffalo tiles with the right palette.  I tried inserting Buffalo at the beginning of the first stage (along with loading his graphics and palette) and it displayed properly in game so I know I have the right index to get the compressed tiles.  I also looked through the s9x source code to see what the Cx4 chip does with the data in ROM when it's copied to the OAM and I don't see anything missing in my code.  The $2101 is set to 8x8 (S) and 16x16 (L) so that's not the problem.

It's hard to tell from the pic what the problem might be.  Buffalo is a pretty large sprite, but then so are other sprites that seem to work fine.  All the right tiles (both 8x8 and 16x16) look like they are there, but they don't have the right position.  X1 bosses, X2 bosses and most enemies in all three games are fine.

My current guesses are:
- Something about the size of Buffalo is making me not calculate x and y position of tiles correctly.
- My index into the tiles is off - maybe by some constant?
- I'm missing some Cx4 transformation.

Any ideas what it might be?

Here's a picture of what I mean:

(https://lh3.googleusercontent.com/-ex6gV8qB9qc/VvNgfmzs87I/AAAAAAAAC8E/d31yWe7NkeQtmz8CxiDERGI5LP4Lc9pSQCCo/s944-Ic42/x3_buffalo_messed_up_sprite.png)

Here are the X2 bosses.  They all look fine.   Only Moth seems to be missing.  I haven't looked at that, yet.

(https://lh3.googleusercontent.com/-DVEGLYWHCPQ/VvNqZ87zmrI/AAAAAAAAC8c/xepPwsnTaekSvc7T0-dreLnBYw4Vo5ufQCCo/s1024-Ic42/x2_bosses.png)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on March 24, 2016, 04:50:24 am
That's..really weird. It honestly looks like the Sprite Assembly is very wrong since the graphics are not setting up properly one bit. If they were, the graphics wouldn't be a mess like that which is usual a sure fire sign that the Sprite Assembly is wrong.

As far as I've seen, the cx4 does nothing with the sprites to effect them. X3 rarely ever used it for any enemy.

I didn't check much on sizes besides the usual 8x8, 16x16 tiles. It shouldn't effect him that much regardless since there's a hell of a lot of OAM free for his sprite setup.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 24, 2016, 11:43:08 am
I'm ignoring the 9th bit for the tile number that gets written to the OAM.  I didn't think it would matter in this case since there are less than 255 8x8 tiles in the decompressed graphics for Buffalo, but it's possible that more than one region of compressed graphics are getting decompressed for him and the sprite assembly (9b tile number) accounts for it.  Maybe something like the health bar gets loaded first from a separate compressed region and that is considered as part of the enemy.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on March 24, 2016, 04:00:32 pm
The healthbars are slapped into VRAM right away at the beginning of the game and when you leave the menu, most notably in X3, so that's not it.

It's very possible he has more than one decompression location.  I never actually thought of that and it wouldn't surprise me.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Jigglysaint on March 24, 2016, 10:45:28 pm
I'm ignoring the 9th bit for the tile number that gets written to the OAM.  I didn't think it would matter in this case since there are less than 255 8x8 tiles in the decompressed graphics for Buffalo, but it's possible that more than one region of compressed graphics are getting decompressed for him and the sprite assembly (9b tile number) accounts for it.  Maybe something like the health bar gets loaded first from a separate compressed region and that is considered as part of the enemy.

I think the health bar is the same a X's health bar in that it should always be loaded.  In fact the boss health bar, if you were to activate it against a sub boss, will actually function against that enemy.  The only thing I can think of is that those bosses have different pieces to them that are all assembled separately.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 25, 2016, 12:35:16 am
If I subtract $20 from all the tile numbers in the sprite assembly it draws correctly except for the few tile numbers that go below 0.  I tried wrapping them back around, but that didn't fix those few.  Two of the bosses are $20 off.  The other three bosses I looked at are $40 off.  I haven't been able to figure out what's causing this or where those tiles that go out of bounds are at.  There's no obvious decompression or DMA to VRAM before that which writes $20 tiles worth of bytes.  Dumping VRAM before that shows unrelated tiles.

March 25, 2016, 12:25:55 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
For now I decided to cheat and have special cases for those sprites.  Add that to the growing list of things that need to be fixed eventually.  I'm going to take a break from the sprite displaying code and work on something else.

https://drive.google.com/file/d/0Bx9gzQZCkH8qRGpJbV90eGo5bGc/view?usp=sharing

(https://lh3.googleusercontent.com/-IZPZFIb683k/VvVngnDIdiI/AAAAAAAAC8w/0ojVPNgvZoUYE1EWtFBPN2IyZemTnFYSgCCo/s906-Ic42/x3_buffalo_sprite.png)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Jigglysaint on March 25, 2016, 03:18:05 pm
I forgot to mention that for some levels in X3, it actually uses a level copy for the changes, such as the boxes in Gravity Beetle's stage.  I think this is also used for Blizzard Buffalo and the second Doppler stage(the one with the water).  I imagine that with some hacking it could be possible to expand the shadow stages to add one for each level, then set a condition(I have located the routine for that) to make each level change.  Of course the only problem is the limited scenes, and stage order data, which I think is only one per level, though I bet even that could be changed too.

Edit:  Forgot to mention that it looks like the robot ride platforms seem to work just like Light Capsules in that the value in the level is an initialization event and the location is stored elsewhere.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on March 25, 2016, 06:54:18 pm
Not sure if you have all of mmx1 sprites loading
correctly yet but x3 looks like they are loaded the
same way. There are values stored between
7f:8000-7f:83ff that the the sprite asm algorithm
uses. The data stored there comes from the 6 bytes
that are the sprite, vram location, and palette...
I'm not 100% sure but I think the sprite data is
loaded that way to prevent people from easily adding
new enemies to the rom. They did a couple things
in mmx1 that I know of to prevent easily expanding it.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 26, 2016, 09:35:25 am
All except a select few of the X1 sprites load fine.  Same goes for X2.  X3 has more exceptions.

I use the 6 byte table as a reference for matching up sprite to palettes.  There's another table that indexes using enemy event id that has the sprite and assembly offsets.

I was going to take a break from sprite loading, but I looked at it one more time:
- Moth uses the Cx4 chip for rotation when swinging.  The assembly code assumes the rotated graphics are already in VRAM.  The originals are not a part of the compressed region.  There is another sprite and assembly offset after you knock him down (+1 of the values associated with his event id) which are now used in the editor.
- Buffalo loads his arms from an uncompressed place in the ROM and then decompresses the rest of the body.  The sprite assembly assumes the uncompressed code is there which is why my original assembly was off by $20.  I assume the other bosses work this way, too.

There's now a feature where you can hold the right mouse button down and use the mouse to scroll around the main screen.

EDIT: Also fixed the emulator so you configure it in settings or just hit the play button and pick the emulator then.  It records emulator path in the registry.

https://drive.google.com/file/d/0Bx9gzQZCkH8qb2toQ1ZPSWo1Tkk/view?usp=sharing
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on March 27, 2016, 08:20:05 am
Yeah, I forgot about Morph Moth being a specific chunk in VRAM that they use for him.

They do the same thing.. sort of.. on the CX4 bosses like the Sigma Head and what not.  Except those are BG3 graphics if I remember right, but they still get messed with the same as the sprites do to an extent.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 29, 2016, 12:06:59 am
Here's the latest version.
- If you hit 'T' to display events then you can click on them when the event editor is open to go to that event.  Enemies show up as their sprite, camera locks are green boxes, graphic/palette/tile changes are purple lines, and everything else is a small pink square.
- Currently selected lockNum is a thicker yellow line now for camera lock events.
- Fixed a camera lock display bug.

I'm probably going to leave event display mostly as-is for now.  The gui code needs to be rewritten and along with that some better event rendering code.

I think I'm going to spend time checking if all the graphic/tile/palette and camera lock changes are stored sequentially in memory.  If so, I can just save the whole memory block when the level is saved similar to how events work right now.  That will make it easier to setup custom stuff rather than having to use the constraints on the current subIds.

EDIT: Fixed the X3 level palette.  It's been bothering me for a while, but only now got around to looking at why it was off.

https://drive.google.com/file/d/0Bx9gzQZCkH8qLXJtUEJBS2RTa0U/view?usp=sharing
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on April 18, 2016, 01:19:12 am
Up until this weekend I took a break from the editor and only made some minor bug fixes.  Yesterday I decided to spend some time trying to use libretro and the example lmsw code to get an emulator working inside the editor (internal emulator).  This evening I got something working.  It's buggy, but I was able to beat the intro stage of X2 inside the editor which is pretty cool.

(https://lh3.googleusercontent.com/-6TyDHcScw9E/VxRsJR3j8eI/AAAAAAAAC-Y/fyVh-1ApRbUNWUDBqkgQ4H4WCstxnyiLgCCo/s860-Ic42/megaedx_internal_emu_1.png)

(https://lh3.googleusercontent.com/-ublYlkRtQYI/VxRsJWRDG7I/AAAAAAAAC-c/TxJkXlhSOlMmtaQ0AxFxxQdlSD36SrhZgCCo/s860-Ic42/megaedx_internal_emu_2.png)

April 20, 2016, 01:04:36 am - (Auto Merged - Double Posts are not allowed before 7 days.)
Here's a short video showing the intro stage being played in X2 inside the editor.  You'll have to excuse my poor playing as I didn't have any megaman game when I was a kid.  :)  I fixed some display bugs and got a basic gamepad controller to work.  It attempts to load the current background tile and palette when the emulator changes it, but it isn't quite right yet.  I'd like to get save states working among other things.

https://www.youtube.com/watch?v=8QIwoahRn7M

April 22, 2016, 12:17:01 am - (Auto Merged - Double Posts are not allowed before 7 days.)
Here's the latest version with the internal emulator.  When you cross a graphics/tile/palette load it misses several frames because the update code is slow right now, but otherwise it runs pretty good.  I have to fix that problem.

The internal emulator works with X1-X3.  It requires libretro (dll included in the zip).
- F12 or file->run internal emulator to start it.  F12 also restarts it.
- Escape to terminate the emulator.
- Space to pause it.
- F1-F10 load state, shift+F1-F10 save state
- T still displays events.
- The current border lock is drawn as yellow rectangle and is updated when the emu RAM is updated.
- Graphics, tile, and palettes are updated when the emu RAM is updated.  The editor doesn't always get these right, though.  These are slow right now and either needs major rework or a separate thread with double buffering.
- Currently loaded sprites have a blue box around them.  Ones that aren't loaded have a red box.
- Locks and some other changes are drawn on top of the emu so you can see exactly when they are activated.
- No keyboard support, yet.  It only works with what I think is a standard joystick controller layout on joystick port 0 (first one).  If you use joy2key try disabling it and see if your controller/joystick works.  I need to add an internal emulator setup menu to assign custom keys/buttons.

There are all sorts of cool opportunities with this because I can read and write WRAM and update the editor as stuff happens in the emulator.  Writing to the ROM/RAM in real time may also be possible, but would be a significant amount of work.  For now I think the save states are sufficient for quick testing.

https://drive.google.com/file/d/0Bx9gzQZCkH8qTlRfZEI3amJZbzQ/view?usp=sharing
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: CrAzY on April 22, 2016, 02:14:26 pm
Excellent job. That internal emulator is so kick ass! I also like that it changes the level for you in the editor as you play. This is coming along quite nicely now, can't wait to see some level changing rom hacks for the SNES series. It has been far far too long.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on April 22, 2016, 02:37:45 pm
You're work on this is absolutely amazing.  I'm SOOO glad someone decided to pick this up and you're going way above and beyond what anyone would've thought would happen with this editor.  Just amazing work!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on April 22, 2016, 09:05:20 pm
Thanks for the kind words, everyone.

I ended up reworking a bunch of the drawing code.  In the process I broke some of the editors and attempted to fix them.  If someone could give this (more experimental than usual) version a try I'd appreciate it.  The good news is that crossing over events which change graphics should be a lot faster in the emulator, although, sometimes there is a small graphics glitch.

<file>


April 24, 2016, 08:27:57 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
I was allocating too much memory for the double buffered level/events (which was locking up some people's computers).  Here's a fixed version.  This also fixes some "VRAM overflow." messages in X3.

https://drive.google.com/file/d/0Bx9gzQZCkH8qMUZwc29SUF9fV2s/view?usp=sharing
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: DackR on April 24, 2016, 09:53:24 pm
Looks like you're the right "guy" for this project. Love where this is going!!

I'll try to find time to take a look at the latest editor this week. I'm really excited to play around with it!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on April 30, 2016, 12:15:17 am
Here's a version with some minor bug fixes.  I made an attempt at adding an internal emulator key/button setup, but it didn't turn out as expected so I disabled it for now.  I should probably take a look at what snes9x does and do something similar.

https://drive.google.com/file/d/0Bx9gzQZCkH8qWEQydWxLSFNvMzQ/view?usp=sharing
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Seeeeph on April 30, 2016, 11:09:35 pm
.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on May 01, 2016, 04:05:16 pm
Here's a new version.
- Fixed a few emulator graphics problems.
- Added internal emulator key/joystick settings menu.
- Updated retro.dll to latest snes9x.

Before running the emulator make sure to go into the settings and change the button mapping.
* Set the joystick drop down to the correct number (likely 0).  Or set it to disabled.  If you use joy2key you probably should disable the joystick in the editor.
* Click on each box (turns green) and press a joystick button or key to change the mapping.  If a key is already in use the box will turn red and won't change.
* Hit Save.

All the keys the editor already uses (e.g. event toggle = 'T') are considered used already.  It would be nice if they were configurable, but I don't want to rewrite that portion of the editor, yet.

EDIT: I messed up the scene, block, and tile editor a few versions back when I added transparency support.  This version reverts that change temporarily.

https://drive.google.com/file/d/0Bx9gzQZCkH8qNUhLWWtDQnpaMHM/view?usp=sharing
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Satoshi_Matrix on May 02, 2016, 04:21:32 am
This gives me hope that there will be a slew of high quality Megaman X and X2 hacks in the near future. Given how damn good both games are, I find it rather disappointing there aren't any level hacks that expand upon the original, or try different things. So many concepts of where power ups and the Light capsules could be hidden. Hopefully someone skilled will make use of this tool very soon!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on May 02, 2016, 09:17:49 am
Well, the is one, it just isn't hosted on RHDN. It's for X1. But, since the tools the creator used were prior to this big update, the hack didn't reach its full potential.

Google Mega Man X Hard Type for more info.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Satoshi_Matrix on May 04, 2016, 06:30:01 am
Yeah, I've seen that. It's a shape that the only existing extensive level hack is one that's designed to be extremely difficult. ROM hacks are at their best when they are balanced for new comers and don't get really tough until near the end game. This is especially evident in Super Mario World hacks with so many of them not being much fun to play because they're so focused on difficulty.

But like I said, I look forward to seeing what people are able to make with this level hacking tool.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on May 22, 2016, 10:24:47 am
Here's a new version:

- Added layout editor (placement of scenes within a level).
- Fixed bug where it would save dynamic tiles (if current loaded tile set is > 0) as part of tile set 0.  Would result in corruption of tiles.
- Added emulator termination to reset tile and palette sets to 0 (to help avoid above problem).
- Added very experimental ROM expansion feature (File->Expand ROM).
- Fixed some X3 bugs where compressing tiles would sometimes corrupt other levels.  Buffalo doesn't compress into a space smaller than the original ROM so it's not possible to save that level right now unless you click 'No' when it warns you the tiles won't fit.

https://drive.google.com/file/d/0Bx9gzQZCkH8qZlJ6QTNtM20xTk0/view?usp=sharing

I added the layout editor hoping that it would be easy to fit changes into the existing ROM space.  Unfortunately, the layout is compressed and changes are very likely to require more space due to how simple and effective the compression is.  Sorting scenes or rewriting the compression algorithm in the ROM might help in certain cases, but wasn't a complete solution.  So I gave up and finally added a feature to expand the ROM - similar to what the Castlevania 4 editor will eventually have.

ROM expansion is very experimental right now but the idea is to move the layout, events, and anything else worth moving into space > than the original ROM size.  Currently it just moves layouts and events and provides $800 bytes per level for each.  Events required some minor hacking of the instructions in X1 and X2.  X3 was a lot more painful because it's already a 2MB LOROM and any additions get address mapped to banks whose low offsets (0-$7FFF) aren't shadows of RAM, etc.  The original event code was using indirect, offset LDs with a bank register value < 2MB and STs to WRAM using the mirrored address.  So the editor changes those to indirect, long LDs using a 3B address in memory with the updated bank along with some modifications to the bank register management.  It ended up requiring only a handful of code changes and it seems to work.

It should always be possible to expand a non-expanded ROM, but it's more difficult to update an already expanded ROM to a newer format.  It's also a little tricky to support multiple different expanded ROM types.  This could be solved with versioning, but I'd rather not add a lot of complication to support this with the editor.  Although, I did end up adding a small expanded ROM header with a version number but it's not used correctly in the editor.  So my recommendation would be to try the expanded ROM feature but don't develop anything with an expanded ROM you don't mind redoing, yet.  It's pretty cool to have $800 bytes for events...

(https://lh3.googleusercontent.com/-inXIRWYJ8Mc/V0HSEMm7LuI/AAAAAAAADD8/OWWysc8O8yEVsC7-C5azS4sMeYDrOWnRACCo/s1280/expanded.png)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on May 22, 2016, 12:06:02 pm
That's probably the best way to go honestly.  Any kind of level editing should expand the ROM, that's how I view it.

And yeah, that was a big problem I had as well with the game on the Zero Project.  Only certain bits of data could be read outside of the normal 2MB range but not all of it.  Mainly the PC's actual graphics could NOT be outside of the 2MB range due to how X2/X3 handle it using the CX4 chip, however, I have a theory that if the data from X1 that does what X2/X3 does without the CX4 chip could be ported over into X2/X3, it could actually go beyond the 2MB without any issues.  I'm unsure if this also applies to compressed level graphics as well though.  I would doubt it since there not actively loaded frequently but it wouldn't surprise me.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on May 23, 2016, 04:26:40 pm
In X3 I got lucky and all the offset LDs (2B OFFSET in memory DBR:OFFSET) were easily converted to long LDs (3B address in memory BANK:OFFSET).  The extra byte in memory wasn't being used so I replaced the PHA/PLB with a ST to the 3rd byte for the bank and turned some other DBR PHB/PLB operations into NOPs.  There was also another section of code that did a PLB followed by an offset LD LowRAM access.  I was able to swap the two instructions so the LowRAM access used the previous bank that supported the shadow so the current level number loaded correctly.

If I remember correctly, the X2 OAM setup for the CX4 was mostly DMA operations with some basic setup and the write to initiate it.  DMA should be fine since that includes a bank.  But I can see the setup/initiation events needing a bank that supports shadowing.  Would converting LDs and STs to long addresses work in that code to avoid changing DBR to a bank that doesn't support the shadow?

The basic sprite assembly format in the ROM is the same for X1-X3.  I was considering adding the OAM setup code to X2 and X3 for a different reason: to remove the need for the CX4 chip.  I decided against it when I found out more than just the wireframe bosses used it for rotation/scaling/etc.  It may also slow down the games to not have the coprocessor do the OAM setup.  I can look into this again if you think there's value.

Tile decompression happens throughout the level based on the object and tile offsets in certain events.  For now I've decided against moving background and sprite tiles to higher addresses because they take up a lot of space and the background tile compression with sorting seems to do a good job of fitting any changes into the original compressed space.  But If I ever want to support major editing of background or sprite tiles I may have to move them, too.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on May 23, 2016, 07:14:14 pm
That would probably fix it in all honesty.  I didn't try to experiment with it too much but yeah there was a distinct problem with them going beyond the 2MB range when they were decompressed flat out.  Maybe it's different for compressed sprites though.

In essence there's not much value to an extent unless someone REALLY wants to graphically overhaul or add a ton of new animations to X, Zero or whichever enemy as that issue with it being outside of the normal bank would cause some problems.  I don't think it's absolutely necessary in the editor but it was a fun idea to toss out and get discussed real quick, it seems like though you experienced something similar so maybe it's all graphics in general.  Unless the editor evolves into a full blown AI, script and event editor, it's probably not worth going into such depth for a minor support that I don't think many people would take the time to understand.

I didn't realize the graphics were decompressed throughout the level.  From what I saw just by glancing at it, it threw everything up instantly for the tiles needed right away.  Though I suppose when it comes to certain objects it probably needs to change something, but I think anything that was destructible basically turned into a sprite the instant it happened.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on May 24, 2016, 01:16:47 pm
Sprite vs background is usually a function of how the player interacts with it.  If explosions or background tile changes are triggered by events and  don't interact directly with the player then are usually kept as background tiles.  When the level starts up it decompresses the initial set of background tiles into VRAM.  As the character runs through and triggers event additional tiles are loaded into VRAM on top of the existing ones.  In 90% of the cases these "dynamic" tiles are actually not compressed so they are just copied from ROM to RAM.  I think there are some exceptions in X3 where they need to be uncompressed.   EDIT: I should clarify that the dust and fireball part of the explosion is sprites, but the changes to the tiles like holes and damage is mostly background tile changes.

If you play through the intro stage of X2 in the editor with events turned on ('T') and the tile editor loaded (I think it refreshes properly).  You can see various parts of the background purple robot tiles loading as you cross events.  When you finally reach the top of the level all the tiles are loaded.  This overwrites tiles that are no longer used and you can see earlier parts of the level start getting corrupted because those tiles are the ones being replaced.  It starts happening almost immediately in the level where the hills outside get corrupted.

If the character is going to interact with the background (falling ceiling pieces in X3 intro or boxes moving in X2 centipede) the interactive pieces are done as sprites.  Sprites almost always need to be decompressed (the major exception seems to be the character and certain boss bits) and the decompression and VRAM loading is triggered by events the character passes through.

If you play through the a level in the editor with events turned on you can see blue boxes around sprites that are currently in VRAM and red boxes around ones that aren't.  In X3 intro the falling ceiling are red until you pass a certain event before Mac captures X and they turn blue since they need to be loaded to appear properly and drop on Zero's head.

The level designer is forced to do memory management of VRAM to give the appearance of more than 64KB as the player progresses through the level.  They do this by placing background tile, sprite, and palette change events.

May 25, 2016, 11:09:54 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
Here's a new version.
- Expanded ROM now supports $60 scenes per level.
- Layout editor now updates when switching between background and foreground tiles in the main window.  You'll lose unsaved changes on the switch, though.

Expanding the number of unique scenes seemed like an important part of designing larger and more detailed levels.  It ended up being $60 for a weird reason - the code runs out of space in RAM with larger values and starts overwriting other things.  I originally tried to add $FF total but it ended up wrapping around in RAM and overwriting all sorts of important things like the controller input and sound related stuff.

https://drive.google.com/file/d/0Bx9gzQZCkH8qdlNhZU42ckQ3b28/view?usp=sharing
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on May 26, 2016, 12:32:10 am
Quote
Expanding the number of unique scenes seemed like an important part of designing larger and more detailed levels.  It ended up being $60 for a weird reason - the code runs out of space in RAM with larger values and starts overwriting other things.  I originally tried to add $FF total but it ended up wrapping around in RAM and overwriting all sorts of important things like the controller input and sound related stuff.

How many more bytes of ram do you need to go from $60 scenes to $FF scenes?
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on May 26, 2016, 09:41:47 am
How many more bytes of ram do you need to go from $60 scenes to $FF scenes?

The scene map in RAM (composed of tile maps) starts at 7E:2800 and I think the next valid thing in RAM is at 7E:F000 (background scene map).

$60 scenes:
$60 scenes * $40 blocks per scene * $4 tile maps per block * $2 bytes per tile map =  $C000 bytes

$FF scenes * $40 blocks per scene * $4 tile maps per block * $2 bytes per tile map =  $1FE00 bytes
($100 might be possible, but I'm assuming that a value of $0 actually means $0 unique scenes in the code right now and would need to be changed to represent $100)

It looks like the code copies all the scene data to RAM at the start of the level and leaves it there.  So without changing the way it's stored it would use almost all of 128KB of WRAM for $FF scenes.  Some ideas:

1) Store the tilemaps as blocks in WRAM and get 4x savings.  Not sure how much it will slow down the in-level scene management code to have to read the block to get the tile. It should just be an extra 1-2 LDs with some address arithmetic.
2) Dynamically load the scene mapping data and have the level designer setup events to identify which scenes are active at different parts of the level.  I don't like this idea.
3) Some other form of compression.

I prefer (1) if we want to increase the limit.  (2) seems like too much extra work for the level designer to worry about.  They already have to manage VRAM.  And (3) would require compression that supports random access and the editor checking that the scene definitions would actually fit in the allocated WRAM space.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: dn on May 26, 2016, 11:56:23 am
Expansion doesn't seem to work with X1. Tried multiple roms, it just flat fails. Not sure if you've coded it to work with X1 or not yet.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on May 26, 2016, 12:15:20 pm
Probably a X1 1.0 vs 1.1 difference.  I only checked it with one of the versions and I can't remember which one.  I'll take a look at it later today.

Make sure the ROM is 1.5 MB in size and doesn't have any major code changes.  The editor does a few checks (size == 1.5 MB, snes header size says it's 2MB, modified instructions are in the right place, etc) on it before expanding and fails if the checks don't pass.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on May 26, 2016, 08:03:13 pm
The scene map in RAM (composed of tile maps) starts at 7E:2800 and I think the next valid thing in RAM is at 7E:F000 (background scene map).

$60 scenes:
$60 scenes * $40 blocks per scene * $4 tile maps per block * $2 bytes per tile map =  $C000 bytes

$FF scenes * $40 blocks per scene * $4 tile maps per block * $2 bytes per tile map =  $1FE00 bytes
($100 might be possible, but I'm assuming that a value of $0 actually means $0 unique scenes in the code right now and would need to be changed to represent $100)

It looks like the code copies all the scene data to RAM at the start of the level and leaves it there.  So without changing the way it's stored it would use almost all of 128KB of WRAM for $FF scenes.  Some ideas:

1) Store the tilemaps as blocks in WRAM and get 4x savings.  Not sure how much it will slow down the in-level scene management code to have to read the block to get the tile. It should just be an extra 1-2 LDs with some address arithmetic.
2) Dynamically load the scene mapping data and have the level designer setup events to identify which scenes are active at different parts of the level.  I don't like this idea.
3) Some other form of compression.

I prefer (1) if we want to increase the limit.  (2) seems like too much extra work for the level designer to worry about.  They already have to manage VRAM.  And (3) would require compression that supports random access and the editor checking that the scene definitions would actually fit in the allocated WRAM space.

I have been slowly working on a few mmx1 projects
for awhile now and one of them is redesigning the rom
so it can play like super metroid. I have two ways that
I came up with for adding more scenes.

1) I have completely removed the graphics
compression in the rom freeing up all ram located
between 7F:0000-7F:7FFF. So now there is 25% of
the roms ram I can use for whatever I want like extra
scenes, weapons and items. My code is already about
95% complete just a couple small things left to do.

2)I will place doors in the level like in super metroid so
when you walk through them it will load new areas so
scene data will be changed in the new areas.


Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on May 26, 2016, 10:48:30 pm
Expansion doesn't seem to work with X1. Tried multiple roms, it just flat fails. Not sure if you've coded it to work with X1 or not yet.

https://drive.google.com/file/d/0Bx9gzQZCkH8qZ2VmVnlpekVKSk0/view?usp=sharing

It should work in that version.  I forgot to try 1.1 where all the instructions I modified were offset by $16 bytes.  I also supported changing the level dimensions up to $20 x $20.  Most likely doesn't work correctly with the background, though, as it will run out of space.

I have been slowly working on a few mmx1 projects
for awhile now and one of them is redesigning the rom
so it can play like super metroid. I have two ways that
I came up with for adding more scenes.

That sounds very cool.  Nice work.  Having free RAM and contained areas separated by doors like metroid will allow for a lot of new mods.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on June 09, 2016, 11:43:02 pm
I haven't been working on the mmx editor lately, but after finding a nasty bug in the map editor I figured it was worth updating it.
- Reworked the tile, map, and block editors to fix bugs and be more usable.
- Improved the menu layout and removed some of the half complete features/editors.

The new editors work like the scene/layout editor: right click does all the selection.  Left click performs the updates.  The map editor tries to guess the palette you want to display the tiles based on which tile you are editing in the selected map.  The map and block editors have the picture of the currently selected tile/map and the previously replaced time.  You can right click on the previously saved tile/map to reselect it.  It's a crappy version of undo, but undo is difficult to add.

https://drive.google.com/file/d/0Bx9gzQZCkH8qR0tPWUtiWHZyb2c/view?usp=sharing
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on June 25, 2016, 10:38:54 pm
I added some preliminary Rockman and Forte support to this version of the editor.  You can view the levels, including events, and also run the emulator.  The event and level data is quite a bit different than the X games.  Not all of the events show up on the later levels because I need to figure out how the bosses trigger the next set of events.  Given that a few more things are compressed I'm going to have to figure out how easy it will be to add extended hirom before adding editing support.  I'd rather not allow modifying compressed or packed stuff in the existing ROM.

R&F uses hirom format and is also 4MB.  The compression algorithm is the same as X2/X3.

Thanks to a friend who answered a lot of questions on R&F and looked through several versions of the editor.

- Added initial Rockman and Forte support (view levels, events, emulator works, no editing).
- Added expansion of checkpoints in the X games.
- Fixed a X2 bug which would overwrite some data it shouldn't if the intro stage was saved.  Can be fixed by copying $2d0 bytes @ $f2035 from an unmodified version.  You will see $00's there if the bug exists.  I found it after noticing the water missing from Crab stage.

https://drive.google.com/file/d/0Bx9gzQZCkH8qUnJIb1h6UUtPb2c/view?usp=sharing
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Seeeeph on June 26, 2016, 01:46:46 am
.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on June 26, 2016, 08:30:42 am
A last minute fix to RF broke the X games.  I fixed that and edited the above link with the correct version.  Thanks for finding that.  I really need to do a better job of testing between "releases".

By disabling the internal editor do you mean disable the joystick so it doesn't try to sample button presses?  Or do you mean disable the internal emu completely so you can't use it?  It supports keyboard, but it won't allow keys that are already bound to the editor.  Unfortunately, there are certain useful keys like the arrow keys and the space bar that are already used.  In the future I will allow all key mappings to be changed or force all input to go to the internal emulator first so you can bind whichever keys you want without having them conflict with the existing editor key mappings.

https://drive.google.com/file/d/0Bx9gzQZCkH8qMWp1bEU5Z1ZkMEU/view?usp=sharing

- Added expanded camera lock support
- Changed max foreground unique scene count to $40 (WRAM limits it)
- Fixed various other bugs
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Seeeeph on June 26, 2016, 05:51:27 pm
.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on June 26, 2016, 05:57:18 pm
What I meant was if it would be possible to enable external emulators like it worked before in xeenamo's original build? Not that I mind the internal emu or anything, its just that I rather use my emulator of choice for testing. Especially if I'm using an msu-1 emulator. Thanks!

If you hit the play button (green triangle facing right) it lets you setup and run an external emulator.  Make sure to save any changes before doing so as it references the file directly.  File->settings lets you change the external emulator.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Seeeeph on June 26, 2016, 09:06:33 pm
.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: renicito on July 05, 2016, 01:43:48 am
hi all, I would like to know if there is a tutorial for using the MEGAED X. Please if you can. :angel:
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Bahamut ZERO on February 23, 2017, 04:29:57 pm
If you're working with Megaman X 1 and want to use the editor's Rom Expand feature, make sure to use a V1.1 rom. V1.0 hangs after you go to start the game.

End of helpful necro post.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on March 19, 2017, 06:03:36 pm
Necro post.  Trying to modify a slight bit of a level in MMX2 and no matter what I do, even if I just open the ROM and save on any specific level, it completely corrupts that one specific level or the entire ROM.  Is X2 able to be viewed but NOT edited?  Maybe I have the wrong ROM, but it seems to load all the data up properly.

Edit: It might actually 'just' be Overdrive Ostrich's level that corrupts.  I tried saving generally on a few other levels, just fine, but ODO's level just instantly causes it to bug out and break.

Edit 2: Seems modifying most levels will cause numerous issues depending.  Morph Moth's level will have some pretty weird palette issues on the ladder section if you save there.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 19, 2017, 08:27:41 pm
I've lost time and interest in doing snes hacking for now so hopefully someone will pick this up and rewrite it in a more modern framework.  Major problems with it:
- Graphics should be decompressed in the expanded version (which should all be expanded to 4-6MB).  I wasted too much time trying to get everything to fit in the original locations.  It's too easy to break the ROM now.
- Game code changes should be written in ASM with help from an assembler to insert them rather than modifying the binary directly.
- Expanded ROM should be better planned out for what it needs to support.  Expanding things in later versions is a huge mess especially if people expect backwards compatibility.
- The editors dialog boxes have a lot of redundant code making them hard to maintain.

Here's the last version I compiled late last year.  Maybe it fixes the problems your observing:
https://drive.google.com/file/d/0Bx9gzQZCkH8qeVVnVmwyM0lORGs/view?usp=sharing

The source is at:
https://github.com/RedGuyyyy/MegaEdX

Good luck to whoever takes it up.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on March 21, 2017, 09:43:01 pm
I've been tirelessly reading through the last 4 pages of forum threads, where I last left off getting the source code for the project. I'm recently unemployed so have quite a bit of free time to fiddle around with the source code. Hopefully, RedGuy has commented the source code well. Problem with Luciano's C++ was that he didn't explain how he interacted with assembly, hex, and linked the different files together in the GUI. I will try re-reading these replies since 90% of it went over my head. Particularly interesting is this event editor working with the sprites. Right now the windows pop up in those tiny little boxes. I'll have to change my screen resolution to try and get a better view of the blocks, level, sprites, etc.

Is the latest working executable in the github source, or should I try clicking on one of the many links and using those?

Thanks. Appreciate all the hard work.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 21, 2017, 11:25:51 pm
The executable is only at the link in my previous post.  I never got around to adding it to the github repository.

You're going to be disappointed about the comments - they are only slightly better than what was there originally.  Another thing to add to the list of things that should be redone/rewritten is the core library should provide a proper interface to modify the contents of the ROM.  A lot of the editor dialogs go in and directly modify the binary which makes it hard to maintain.  The SCV4 editor did a better job at this, but it still wasn't great.  With a solid core library to access the various data structures in the ROM you could then rewrite the GUI code and clean up a lot of the hacks.  I basically learned about snes architecture and rom hacking by working on the editor.   In the process I wrote some ugly code and it's way past the point of needing a rewrite.

The editor source isn't a good place to learn how the ROM works.  You're better off looking at traces and stepping in a debugging enabled emulator to look and match that with what the editor does.  There are a few people I know who are doing mmx1-3 hacks including Justin who can also probably help you understand the game engine.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on March 22, 2017, 05:36:34 am
I believe the open-source of SMILE (super metroid) is available to look at. That will help at least me understand game-specific editing a little more. Where did you go to understand how to deal with Visual Basic and C++ GUI handling, such as how to attach a function to a button, open a window, close a window, etc.?

I was able to do some minor tweaking to the level design, such as change the colors of the enemies using offset values which was kind of neat. I remember trying to use the palette or tile editor before and grabbing my hair. My ultimate goal when trying to get Lucciano to release the source was to create a super user-friendly game editor. Even possibly being able to just drag and drop enemies, or palettes/tiles to change the design of the level. Only messing around for just an hour I was able to completely screw up one scene and then completely undo my mistakes manually. Just adding an Undo button, probably wouldn't be too difficult, you see it even in Windows paint, probably wouldn't take too long once I figure out the libraries.

I agree it really is a shame that you didn't comment the code (#1 rule in programming). However, I don't want to criticize you too much because I'm pretty rookie when it comes to dealing with the GUI, and I majored in computer science, yet focused on mainly web programming, not game or graphic design. The x2/x3 and internal emulation was pretty neat. Again if you could point me to some free guide online on how to program the GUI in C++ that would be great. I have VB 2015.

Just a side note. MM has mainly been ignored in the gaming community, for more popular games, yet even super metroid snes had major overhauls. I think it didn't become popular on the SNES because it completely avoided save games, and then on the N64 it looked really ugly. They haven't even had any recent remakes of the games, despite releasing some collections for the ps3 and the wii. Nintendo has mainly dumped MM, possibly because Capcom cross-platformed onto the Playstation quickly who knows. I've seen many rom hacks for the NES I'm really surprised only a few people have tried tweaking the 16-bit version. Once this project becomes an amazing utility that is very user-friendly there could be several new hacks in the next 5 years or so. I just watched a trailer for Megaman X Corrupted earlier. The developers are making the game on Adobe Flash I believe. Ridiculous. The project has been in the works for a few years now. It may even get abandoned before completion without releasing any beta files.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on March 22, 2017, 09:19:34 pm
The editor uses windows API calls directly - probably because it was originally written many years ago.  I just searched API calls from the source and read Microsoft's documentation on them.  That coupled with running it in a debugger is how I learned.  I've played around with MFC (SCV4 Randomizer) and QT (bsnes-plus) since.  QT is pretty intuitive and there are plenty of examples available.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on March 23, 2017, 05:00:11 am
Hi,
I've saved some videos on youtube about MFC and QT. Saw a really good example of how to edit a rom using a hex editor. I actually got into the program today and messed around with some things. I just added a menu item, but I was able to get it working properly so that's a big boost to working further on it. I've got a few additions I'd like to make, so I'll try working on it some more. BTW, there's a megaman x randomizer github online, not sure if you know that or if somehow you use the scv4 to randomize mm levels.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on March 25, 2017, 09:21:16 pm
Necro post.  Trying to modify a slight bit of a level in MMX2 and no matter what I do, even if I just open the ROM and save on any specific level, it completely corrupts that one specific level or the entire ROM.  Is X2 able to be viewed but NOT edited?  Maybe I have the wrong ROM, but it seems to load all the data up properly.

Edit: It might actually 'just' be Overdrive Ostrich's level that corrupts.  I tried saving generally on a few other levels, just fine, but ODO's level just instantly causes it to bug out and break.

Edit 2: Seems modifying most levels will cause numerous issues depending.  Morph Moth's level will have some pretty weird palette issues on the ladder section if you save there.
That's a shame. I didn't notice it when I modified the intro stage, and Wheel Gator's stage in X2. I can safely say the editor works fine for X1 though, even after expanding. Unless I've missed something, of course.

Hi,
I've saved some videos on youtube about MFC and QT. Saw a really good example of how to edit a rom using a hex editor. I actually got into the program today and messed around with some things. I just added a menu item, but I was able to get it working properly so that's a big boost to working further on it. I've got a few additions I'd like to make, so I'll try working on it some more. BTW, there's a megaman x randomizer github online, not sure if you know that or if somehow you use the scv4 to randomize mm levels.
Heya there. I'm an active user of this editor, having 2 active projects, and 1 future project with it in the Insane Difficulty Forums. So I'm highly grateful for all of the effort you seem to be willing to put in advance. :D If you need any help with the testing, or I don't know, something. I have some basic ASM knowledge (and only have "ideas" of basic programming. Don't know any programming language asides from that), which I've used in my MMX Hard Type projects. [disclaimer: I'll try to stay active in this thread from now on, but if you ever need to contact me and I'm not active, I'll sure be active in the Insane Difficulty forums. Life's busy for me these days. I'm also on Discord btw].

I've helped the guy who's done the randomizer, it's a really cool project.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on March 26, 2017, 02:34:13 am
I looked at Ostrich Overdrive level. I loaded both MMX2 with and without headers. The level/map seems to be loading incorrectly on both versions unfortunately. I checked through each level on all 4 games supported (mmx1-3 and rockman and forte). Seems to be the most damaged level. Most levels are loaded pretty standardly without too many if/else statements for exceptions. It's most likely a corruption in the rom that doesn't follow the rules (perhaps the level before used more memory than typical so the pointers are off). I wasn't able to get around to fixing the problem though since there's thousands of lines of code to look through.

I'm still learning how to try and manage this huge project more efficiently and have tried to understand Visual Studio better in general so tried to learn how to use the debugger to step through the code. You know the stuff where you can see variable values change etc., so you know where to go. I was able to use the program to do just something really simple. I wanted to add a minimize button next to the exit button for example on the dialog boxes/windows. So instead of reading through each line of code, like I typically do, I just clicked through the menu in the GUI and clicked an option to allow minimize boxes. I wish coding was always this easy.

Honestly, I'm trying to take my time learning all the hard stuff- vram, hex, asm, etc. If you try and learn everything in a day or two you will burn out and probably punch your computer screen never to return haha. I've programmed in assembly before (x86, NASM) so I'm familiar with it, although I'd never use it preferably. (Notice today how games are all 10gigs I doubt most students are using it also). I found a good wiki to learn some great stuff about the instructions SNES uses since it's different than other stuff. If you have any info on it, or tips that you think would be helpful feel free to message me about them. Looks like MMX3 is pretty well-documented, but few others are.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on March 26, 2017, 11:25:59 am
I've got more in-depth notes when it comes to the gameplay portion of X3 but not much else on the level system and such.  X3, I'm pretty certain actually, was built upon X2 so they share pretty much the 'exact' same system.  It'd be just a matter of porting the data over and altering a few exceptions.  Otherwise, they are virtually identical.

Event scripting is a bit of something I plan to study later on down the road.  I have a basic idea of how it flows in X3 along with a couple normal commands that are used quite frequently, but that's about it.  Unfortunately not much can be done on that front until the level system is stable.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on March 27, 2017, 12:16:33 am
Necro post.  Trying to modify a slight bit of a level in MMX2 and no matter what I do, even if I just open the ROM and save on any specific level, it completely corrupts that one specific level or the entire ROM.  Is X2 able to be viewed but NOT edited?  Maybe I have the wrong ROM, but it seems to load all the data up properly.

Edit: It might actually 'just' be Overdrive Ostrich's level that corrupts.  I tried saving generally on a few other levels, just fine, but ODO's level just instantly causes it to bug out and break.

Edit 2: Seems modifying most levels will cause numerous issues depending.  Morph Moth's level will have some pretty weird palette issues on the ladder section if you save there.

I've been trying to debug this problem with the Overdrive Ostrich level. I've messed around with a few variables and haven't figured out why it's loading incorrectly yet. There's more than 20 vital variables that are used in each class function, so debugging is a bit tedious, especially since there's no comments in the declaration/header section. Although, I noticed if you use the EXPAND ROM feature in the program and save on the OO level, even after editing the layout/scenes/blocks, etc. it will finally save correctly. Saving at 2.5mb instead of 1.5mb doesn't seem like too bad of a solution. And I tested other levels of the rom they all seem to work fine as far as I know.

I also ran the Morph Moth level, after editing several features and saving and wasn't able to recreate your bug.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on March 27, 2017, 03:37:32 am
I expanded the ROM as well and kept getting the same bugs. I wonder if the ROM I have is a different version or something.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on March 27, 2017, 04:46:12 am
There's only 1 version of Megaman X2 as far as I know. MMX1 is the one with 2 different versions. I ran the rom in ZSNES (which most people don't recommend using), but it also worked fine in bsnes. So I removed the header from the original rom before expanding, but the game title still shows up in emulation so I don't think it did it correctly. Anyways, here's checksum info it might help out:
Original headered rom: 94e9a109170b6b835b73e6e24220ed97
Unheadered rom: 67905b989b00046db06df3434ed79f04

Both of those roms are the original 1.5mb snes roms.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on March 27, 2017, 05:45:06 pm
I downloaded a different ROM and it seems to work fine.  Looks like the ROM I originally used was actually 2MB (It basically copied the last 0.5 to fill the rest of the 2MB space).  Got it working now it seems like.  This'll come in handy down the road!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on March 29, 2017, 09:00:21 pm
justin3009:
Hey I've been talking with falchion22, about trying to edit his MMX1-Zero rom to include Zero's hair. (basically I'm trying to get my feet wet in hacking, figured this would be an easy start). He mentioned that I should edit the disassembled ASM to allow more tiles for Zero, because the sprite uses 64x32 instead of the regular 16x16 for MMX1. I noticed you did a Zero Project for MMX2 and MMX3. Did you have to get in there and edit any hex, or asm for the file? Or did you just basically overwrite the original MMX sprites using a program like Tile Layer Pro and then just change the palettes to reflect the color?

Thanks.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on April 10, 2017, 10:55:49 am
Redguy,
Can you explain what the different colored boxes mean? I think you covered it in a previous thread, but it's not included anywhere in the program explanation (and there's no help file). I may edit this post to change after searching through this long forum thread.

Well it turns out that most of my work contributing to this project was nearly wasted. I added an 'End Emulation' to the menu options, but it looks like if you just press the Escape key it does the same thing. I didn't see the command in the text file for the program when working on it myself. I'm working on adding an Undo button, so you can't fix any mistakes you might have accidentally done instead of having to reload the entire program. I've noticed that's very tedious. Unfortunately, I thought the SMILE program was open-source also, but searching around online I only found dead links to the source code. I think Lunar Magic is also closed-source. Each rom handles things differently, but seeing how they do things may always help. I also would like to output a separate window to display the title screen and a window solely for editing the megaman x sprite (one which can be zoomed in).

Editing text is easiest using a hex editor. It's pretty hard to rewrite an entire program for something that's already done pretty well to begin with using a program less than 1mb and it only takes about 15 minutes to learn how to do. So I probably won't attempt to do anything with text via MegaEd X.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on April 10, 2017, 02:26:22 pm
justin3009:
Hey I've been talking with falchion22, about trying to edit his MMX1-Zero rom to include Zero's hair. (basically I'm trying to get my feet wet in hacking, figured this would be an easy start). He mentioned that I should edit the disassembled ASM to allow more tiles for Zero, because the sprite uses 64x32 instead of the regular 16x16 for MMX1. I noticed you did a Zero Project for MMX2 and MMX3. Did you have to get in there and edit any hex, or asm for the file? Or did you just basically overwrite the original MMX sprites using a program like Tile Layer Pro and then just change the palettes to reflect the color?

Thanks.

Totally missed this reply.

I deciphered the Sprite Assembly, Animation Data and VRAM data for MMX2/MMX3 essentially.  I'm pretty sure MMX1 uses the same thing but it doesn't send the data to the CX4 chip to be messed with at all.

The main thing for making larger sprites we'd want to worry about is the Sprite Assembly.  I'm not sure if I remember the case or not, but for X2/X3 to even add in new animations for X or Zero I had to separate them entirely from the rest of the game.  X3 mainly has it where X/Zero are their own entities and don't share the main data area with any other sprites, X2 however doesn't have that yet since I haven't figured out how to handle the 'NPC PC' system like X3 yet.

Animation data speaks for itself in how it works.

VRAM data is basically tells where the graphics are from in ROM and how much to store into VRAM.  I believe it also includes where to store in VRAM as well.

To get things into X2, I basically just copy/pasted what I did from X3 into the game since their engine is quite literally the same on that account.  I'm pretty sure I can do the same thing for X1, but I'm just lazy.  It's a bit of a tedious process but it's definitely doable, no worries there.

It'd be a lot easier to handle if there was an editor for the sprite assembly and such as it'd make things tremendously more doable with little to no time consumption in the long run.

Edit:

Also, the text is easily editable if you use Atlas/Cartographer and move the data into empty space.  Works wonders.  The only 'REAL' annoyance with text editing though is how many damn commands the game uses per string.  It's pretty ridiculous but they are necessary.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: RedGuy on April 10, 2017, 10:00:51 pm
Redguy,
Can you explain what the different colored boxes mean? I think you covered it in a previous thread, but it's not included anywhere in the program explanation (and there's no help file). I may edit this post to change after searching through this long forum thread.

With event editor open and selecting an event:
* Red Box - event trigger (X works on block boundary, Y works on pixel boundary of event position)

Event specific:
* Purple Lines - palette/graphics/tile dynamic changes.  If you click a graphics change the editor will attempt to let you know which enemies are loaded after the event: red - not loaded, green - loaded in the forwards direction of the event, yellow - loaded in the backwards direction of the event, blue - loaded in both directions of the event.  The subId is split into 2 nibbles that index into a table for forwards/backwards lookup depending on the direction X is traveling when crossing it.
* Green Boxes/Yellow Lines - Camera locks.  When event is triggered if X crosses into the green box then the camera bounds are changed to the yellow lines.

Event type.  If the editor doesn't know how to display them they end up being pink squares.  Most event types 0 and 1 show up this way.
* 0 - usually objects like powerups
* 1 - various scripted events
* 2 - palette/graphics/tile dynamic changes and camera locks
* 3 - enemies and some interactive objects like elevators and platforms
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on April 16, 2017, 06:54:47 am
Thanks RedGuy that helps a little. justin, yea if there was better sprite handling the program would be a lot more appealing. MegaEd already decompresses the graphics, but if the program let you recompile the sprites from the rom as they appear in-game, then let you edit them, and then reloaded them in the rom in the correct locations it would make sprite handling better.

Anyone seen some other Megaman X engines out there? I think one good one pretty closely resembled MMX and the true game physics:
https://www.youtube.com/watch?v=Dx3_cOdIeu8

I found this video from another video about abandoned mmx fan games. The author of that program started and re-started over a several year period. Looks like he made it with game maker.

[Update: I pretty much gave up on trying to modify that bug in the Overdrive Ostrich stage, but I was replaying the game (to collect all Zero parts for an alternate ending) and came across that stage. Actually, playing that level helped me understand that bug. So if you guys don't remember at the end of the level you take a rocket ship from below to a different area of the level way upwards. So the bug drops you onto the area where the boss fight is, except there's no boss. This is most likely because opening up the stage overwrites default cursor values or something. I'll take another crack at it.]

[Update2: I thought editing MMX-X position, Y position, camera X position, or camera Y position would fix the bug, but checking the values of a rom with working OO stage and buggy OO stage only values that changed were cam Y position, but changing those values to the default values in the working rom didn't solve the problem. It just made megaman start 3 feet in the air or so. I think the program overwrites crucial assembly in the rom that deals with that level and the rocket ship and where MM starts. Maybe instead of there being just backgrounds/graphics in that location of the rom like on most levels it has other info such as telling the emulator/snes 'hey megaman starts at the bottom of this level, not at block/layout/map 00,00 like most levels'. Somewhere in a few of the functions that deal with loading the level or saving there has to be an new exception written that deals with that level (level 7, type 1 for MMX2) that will fix this bug. It's loading the tile/map for where Megaman X fights Overdrive Ostrich first @ block 0 so maybe it incorrectly stores that part of the level in that location in memory, overwriting the original beginning of the level. I'm going to have to try and find the address in memory where MMX2 level 7 starts and then compare hex/assembly of buggy and working roms so I can better see what is making the error. Simply setting breakpoints and debugging the program in Visual Studio is not as helpful. I've also noticed that the program loads the wrong palette for this level. The level is supposed to have desert-like ground after exiting the cave not concrete like ground. I'm not exactly sure why the program ruins this part of the game at this level yet doesn't create errors when other key events happen- such as during the dig machine on MMX1, Sea Canthller on MMX2 or the many X-hunter routines. I haven't saved at every level in the game or done extensive debugging, testing so maybe it also crashes during other save areas. If anyone would like to comment on this note please do]
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on May 04, 2017, 08:24:23 am
Good news! At least for justin3009 and anyone else worried about the Overdrive Ostrich bug. I was able to pinpoint the error. If you have the open-source MegaEd X files here's the code to correct, just open up MegaED X.cpp and scroll down to 'case ID_FILE_SAVE:', this was line 454 for me. Scroll down towards the bottom you're going to change one line.

old code:
Code: [Select]
if (newLayoutSize > layoutSize)
switch (MessageBox(hWnd, "The layout size is more than the original layout size.\nYou can corrupt the data of ROM if you don't know what are you doing.\nAre you sure to continue?",
"Warning", MB_ICONWARNING | MB_YESNOCANCEL))
{
case IDYES:
WRITE_LAYOUT:
// Update the layout
nmmx.SaveLayout();
break;
case IDNO:
break;
case IDCANCEL:
return 0;
}
else goto WRITE_LAYOUT;

new code:
Code: [Select]
if (newLayoutSize > layoutSize)
switch (MessageBox(hWnd, "The layout size is more than the original layout size.\nYou can corrupt the data of ROM if you don't know what are you doing.\nAre you sure to continue?",
"Warning", MB_ICONWARNING | MB_YESNOCANCEL))
{
case IDYES:
WRITE_LAYOUT:
// Update the layout                                             
nmmx.SaveLayout();
break;
case IDNO:
break;
case IDCANCEL:
return 0;
}
else if (nmmx.type != 1 && nmmx.level != 7) goto WRITE_LAYOUT;

Basically, you're just adding an if statement in the WRITE_LAYOUT jump to skip doing the SaveLayout function for only Overdrive Ostrich, during the else. It still will try to use SaveLayout when checking if old layout size matches new layout size. This basically renders the layout editor useless. It's kind of a temporary problem until I can find a permanent solution. It was causing problems with the layout when saving. Although, I'm not sure if it's needed for other levels, I've included an if statement just in case it causes issues. Actually, running across another bug on the Bubble Crab stage is also fixed by a similar if statement. Right before the COMPRESS_TILES routine put the same exact if statement but change the level number. It was creating issues with the font during saving.

new code:
Code: [Select]
else if (nmmx.type != 1 && nmmx.level != 3) goto COMPRESS_TILES;

One important thing to note and that is not my fault because I checked in the latest MegaEd X version is that when you try to save a file with a header it will crash when you run it in an emulator. I'm not sure exactly why it does this I looked through SNEScore.cpp, MegaEDcore.cpp, and MegaED X.cpp for about an hour and couldn't narrow it down. In Luciano's MegaED X version it could save both headered and unheadered roms. So to save correctly in RedGuy's version either use an unheadered rom, or use the 'Save As' feature on headered roms. Weird that Save As would work, but not Save. I had also tried to save a MMX1 rom with a header and it still crashed. Something happened across versions that caused issues. If anyone has been able to locate the problem please let me know.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on May 19, 2017, 12:29:08 am
Good news I have figured a way around the bug in Overdrive Ostrich. It has do with the compression algorithm. Basically for some reason the counter wasn't reaching high enough so it wasn't loading enough zeroes in the program, causing the layout to load way up in the level. When I manually inserted the correct values into a byte memory address array it was able to load fine, after I added some more zeroes (it needed about 296 zeroes and the max value the array could hold was 255 so I had to do a work-around). Unfortunately, I've been fiddling with it all day I can't make it look pretty. I basically wanted to just jump over 6 values in the array and use the original, but it causes issues so I have to manually insert the values. Another problem is that it uses absolute values, rather than relative values. This may cause issues with anyone working in the layout editor who changes too many things. But this is terrific I was able to finally use the layout editor and change the level around in an unexpanded rom in Overdrive Ostrich.

I'm not sure how major this bug was, but it was my white whale I had to solve it. Yea expanding the rom works and nowadays memory is so cheap that people have no problem saving NES games that are 10 gigs, but the best thing about this fix is someone who doesn't know this program and its glitches can play around with this level without knowing what they're doing and not have it be glitchy on accident and have to search for days only to finally figure out expanding the rom fixes the glitch. I'll post an edit with the code in the next few days it's kind of late. If you think this warrants a new release on github let me know. There's still several things I'd like to try to fix as far as the levels. I've only gone as far as testing mmx2 though so mmx3 is a whole other ballgame, and well even though rockman&forte is supported I'm not sure how well the program handles it. for mmx2/3 there's so many offsets and separate programs to deal with tiny things and it just seems like little is included for r&f. I'm not sure if it's just extremely compatible, or no one has tried to tame the beast yet. Levels load fine and everything. I haven't tried saving anything though.

Original code in CompressionCore.cpp:
Code: [Select]
WRITE:

if (!sizeOnly) {
dst[writeIndex++] = counter;
dst[writeIndex++] = buf;
}
}
                                        else..

Modified code:
Code: [Select]
WRITE:

if (!sizeOnly) { //debug:i<155 will save but can't edit layout

if (writeIndex == 27 && buf==0 && overdrive_ostrich) counter += 34;
dst[writeIndex++] = counter;
dst[writeIndex++] = buf;
if (writeIndex == 19 && overdrive_ostrich) {
dst[writeIndex++] = 254; //original values pulled from working rom
dst[writeIndex++] = 0;
dst[writeIndex++] = 254;
dst[writeIndex++] = 0;
dst[writeIndex++] = 238;
dst[writeIndex++] = 0;
i = 517; //next non-zero value in src
}
}

And 'overdrive_ostrich' is a boolean value that checks for nmmx.type, nmmx.level, and expandedROM. It's set to true if all those variables match (1,7,false) and I pass it as a parameter when calling LayoutRLE in MMXCore.cpp. You will have to change LayoutRLE.h also if you add the parameter of course, but this allows you to save the layout when editing level 7 in mmx2. I know it's complicated, but I've worked on it a lot and this works. I tried to make it less ugly by just increasing the writeIndex by 6 rather than rewrite values that the original dst loads in a working rom, but that didn't work (it's a byte array initialized with an address location not a typical array where you define the size and then iterate through). I also tried to use relative values rather than absolute but couldn't figure a way to do that. I'm afraid with too much tinkering people will mess up these values, or that a MMX2 rom with a different checksum value will behave differently. When working with MegaEd for this level it would pass 234 instead of 254 at index 19 and then skip 254 and 238. What those values do is set the counter to write the buffer a certain number of times. So you see the buffer is 0 in all those cases so when loadlayout runs the RLE decompression it's checking for those values so it knows to write the buffer however many times. This is why the rom was screwed up after saving; these zeroes need to be outputted or the layout will load way high up where the cursor doesn't read.

I know this is extremely complicated and tedious. I'll just create a github so anyone can download an executable and not have to worry about this junk. I wanted to wait until I added the Undo option to the program before I released the source on github. I suppose I have time no one is begging for fixes on the MMX2 game on this specific level.

On a separate note, I stumbled across a neat little project someone is doing involving Megaman X, although very optimistic, and it looks like it's been abandoned:
[url]http://sprites-inc.co.uk/archive/index.php?thread-1786.html[url]
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on May 23, 2017, 04:10:21 pm
I'm quite new to MMX hacking and I was wondering how or if I can edit the font? I know it's compressed somewhere at E0200 but I can't seem to edit it or anything. Will your editor eventually support font editing as well? I'd love to add more symbols for a translation I'm making. :)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on May 24, 2017, 02:47:15 am
Ice Man,
The font in Megaman X uses RLE compression, and LZSS compression for MMX2 and MMX3. You don't need to worry about this though, lunar compress will decompress the graphics for you. (I'm not sure if it's able to correctly decompress x2 or x3 however). Your best bet is to extract the graphics using lunar compress and then edit them using tile layer pro or tile molester. I can jot down a note to look into adding the font to the editor, but it would be pretty strict such as pulling a specific sized block from the game at the specific offset, then re-inserting that exact block back into that game at the address location after editing. It looks like I can just copy the Tileset editor window and put the font in there. Are you sure it's at location E0200? How large is the block? Is that the snes address or pc address?

It looks like the user kabuchi203 was successfully able to translate Megaman Battle Network into Spanish on the GBA and he needed to add a couple letters for the Spanish alphabet you may want to shoot him a message. You'll probably want to expand the rom and then put the new font table in the extra space, assuming the font table would be larger, although then you'd have to re-assign every location that uses a letter.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on May 24, 2017, 06:25:24 am
X1/X2/X3 I'm pretty sure all share the same decompression routine so I wouldn't worry there.  If they are different, X2/X3 for sure has a decompressor and even code on this site too to do it in it's own separate program.  Mainly focused at X3, but X2/X3 share the exact same routine so it works vice versa.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on May 24, 2017, 07:10:33 am
@pianohombre:
That's the problem. I',m not very familiar with Lunar Compress yet and don't know how to extract/reinsert the graphics properly.
Editing them with a tile editor is the least problem for me.
E02000 is PC address, iirc. It did include the font and it was like 64KB large.

What does MM:BN has anything to do with the SNES?
I know there's a French translation of MMX. Might as well ask the author. Thanks!

EDIT: Got the help needed. Thanks though!

Font offset is at E6BB4.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on May 25, 2017, 01:00:14 am
Iceman,
glad you got the help you needed. There was an example in the LC source code notes of how to extract MMX font. It looks like you must have found that because you got that same exact offset. If you're translating using Roman alphabet probably better off just editing the French version because they have more than 26 letters.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on May 27, 2017, 03:52:09 pm
Actually, in the original LC example there's no MegaManX but I found it on someone's github. Might've been a modified version? Either way, the offset for the font is actually wrong.

It's 2BPP located at E6A99. I was able to add special signs that way and reinsert back.

E6BB4 had some signs missing.


However, I'm curious, what format does MMX2, MMX3 and Rockman & Forte use? Does anyone know?
I'm planning to do complete German translations for all of them. I know some exist but they're old, unfinished and have alot of errors.
Thanks in advance for any help!

Sorry for derailing this topic too much though but I think this fits best in here. :x
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on May 28, 2017, 06:14:24 am
Ice Man,
no problem as far as I know I'm the only one working on the source code. The offset you listed earlier worked for me on a headered rom. I checked afterwards with tile molester. (it's in the lunar compress readme file). I can tell you right away that the same offset won't work for Megaman X2 because I tried it. I actually thought it was a good idea to add a font editor to the program, and it won't necessarily be so hard since the tile editor window has all the color editing functions for it already. I wanted to add a titlescreen editing window into the program as well, which would be practically identical.

The reason I mentioned that x2/x3 probably uses lz-22 compression, which justin3009 (praise be to his megaman prowess) disputed, is because the LoadFont function in the program uses graphics decompression involving lz-22 not the typical rle3. I did take a look at the program the other day and one of the parameters returns a so-called font pointer offset, but it returns the same value for each game (and a wrong value nonetheless) so I'm not exactly sure how it pulls the font, because it definitely does for debug info in the editor. I was going to trace through bsnes debugger this week for some values so I can pm you, unless you're too impatient to wait a couple days or just find them yourself.

Happy programming,
pianohombre
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on May 28, 2017, 09:49:46 am
http://www.romhacking.net/documents/205/ - Here's the document for the decompression routine for X3.  It works for X2 as well from what I had to test way, way back.

http://www.romhacking.net/utilities/552/ - There's also this for X3.  No source unfortunately but it definitely works.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on May 28, 2017, 03:36:29 pm
pianohombre,
adding that would be really sweet. Either way, my address worked on a headerless Mega Man X 1.0 US ROM.

Anyway, sounds good from my side. I'm in no rush with my translations. I can already work on the scripts and add additional things later on and keep notes. :)


justin3009,
thanks for the document. Definetely going to check it. I'm aware of that tool for MMX3 but it actually expands the ROM to 4MB and stores the graphics in another format (?) at 20000+ in PC address. I'd love to actually decompress them myself without expanding the ROM. The document might be of good help. Thanks again!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on May 29, 2017, 06:40:53 am
I was looking through the graphiX3 and decompression script today. Finally got the decompression working, after I removed the header from my X3 rom. bin file works great just cuts off the titlescreen a little, so probably have to edit the size somewhere to fix this change. graphiX3 also works ok, just extracts everything into multiple bin files. it basically does the same thing as the decompression script, but for each graphics pointer location (there's 200 or so), plus it can restore the compressed graphics but only for MMX3. I found the pointer table and after some number crunching was able to find the font pointer for X3.

font pointer=E1CA4
size=A000

You can use the original decompression script in Visual Studio or whatever just change the pointer location and size it will extract the font fine. I noticed Lunar Compress isn't able to do this. That's the plus side of these scripts (although megaEd X can of course do this as well). I think I found the font pointer table in MMX2 it would be nice of graphiX3 was open source I could just change a couple values and find the other pointers quicker too. I'll try tracing this week. Hopefully it isn't too tedious.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on May 29, 2017, 07:52:35 am
Well, X2's menu graphics and menu font I think are at: 22:8FB9 (LoROM address) with the size of 1600.

However, the font itself is at: 15:C1B0 (PC Address) decompressed if I'm seeing this right.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on May 30, 2017, 05:07:13 am
The weird thing is, the font is also decompressed for X3 as well as compressed.
Thing is, both are actually used in X2 and X3. The compressed font is used for the stage select layer 3 and ending text while the decompressed font is used for the intro cutscene, dialogue boxes, etc.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on May 30, 2017, 09:58:32 pm
The font is like 95% decompressed in the rom. Some of the bigger text is cut off and when decompressed it fixes this. Too bad the values in tile molester don't relate to actual hex pc addresses. I found some of the original source code online he posted it in a forum, so I can just copy/paste and then decompress all the graphics into separate bin files. This will help me find the pointer I'm looking for since there's about 150-200 of them. This will also be helpful for mmx1 and rockman & forte.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on June 01, 2017, 05:35:51 am
I just found a tool that can compress and decompress MMX2 graphics so I'm all set actually.
If you're interested, here's a link: http://romhackers.org/modules/PDdownloads2/viewcat.php?op=&cid=3

Also has tools for MMX, MM7 and R&M.

However, R&M one seems to be buggy when reinserting edited graphics back since it doesn't insert them to their correct locations but rather right after the next file.

Thanks for all the help though! I might as well make a MMX hack one day. :D
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on June 02, 2017, 02:04:41 am
Thanks IceMan,
it looks like these programs probably store the pointer locations in the log.txt file. This will save me some time finding the pointers. Hopefully someone will find it useful to be able to edit the font and titlescreen once I'm finished adding these functionalities in.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: NiO on June 02, 2017, 03:55:57 am
Thanks IceMan,
it looks like these programs probably store the pointer locations in the log.txt file. This will save me some time finding the pointers. Hopefully someone will find it useful to be able to edit the font and titlescreen once I'm finished adding these functionalities in.

Time ago I was helping a guy with a Protoman hack in mind, but we weren't able to edit the tittle, so I'm sure there will be people that will find that really useful!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on June 02, 2017, 04:26:08 pm
Glad it's useful to you guys, however, if anyone actually figures out how to compress/decompress graphics properly with the Rockman & Forte tool, I'd appreciate it.

I know it creates a XML file with all pointers but changing them nor the size does anything to me. So I actually went to fix it manually since my edits made the compressions for the font smaller. This way I could put the untouched graphics back to its original location but I'm stuck with another file that turns out 20000 bytes larger than the original due to my edits. I've got no idea how to properly repoint it with that program, assuming that's even possible. In case it isn't I'll have to find the pointers manually, I guess.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on June 05, 2017, 01:01:04 am
So I actually went to fix it manually since my edits made the compressions for the font smaller. This way I could put the untouched graphics back to its original location but I'm stuck with another file that turns out 20000 bytes larger than the original due to my edits. I've got no idea how to properly repoint it with that program, assuming that's even possible. In case it isn't I'll have to find the pointers manually, I guess.

If you just use the MMX3 decompression code you're able to decompress the graphics without touching the rom. For some reason graphiX3 expands the rom during re-compression (possibly because it can't get it exactly right). An extra 20kb for a translation patch shouldn't be that big of a deal. Anyways, with the Rockman&Forte tool I had some trouble at first, but I got it to work. Make sure you use an original Japanese rom, because it will give an error msg for Megaman & Bass (the English translation). Usually, in my experience the pointers are typically in the same location for Japanese/English roms.

Font table in English for Rockman&forte(unheadered rom): (snes address/hi-rom) offset- D96A9C size- AE4
Font table in English for MMX2(unheadered rom): (snes address/lo-rom) offset - 1cc180 size- 0663

**note: even though the size is listed as "0663" for MMX2 you'll get the same decompressed graphics in the rom. Use A00 for the size to get the full font.

On a separate note, I'm not sure if anyone knows this, but there was a PSP remake of Megaman X called 'Megaman Maverick Hunter X'. Capcom was planning on redoing a lot of the X games, but it didn't sell very well so they dropped plans. Iceman, you may also want to look into translating that game, although I couldn't find any tools for that. The game has a 25min movie unlocked after you beat the game. You can also defeat Vile in the intro stage, but other than that it's about 90% the same, other than a 2.5D graphics update.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on June 06, 2017, 03:34:18 am
I was talking about Rockman & Forte.
Mega Man X2/X3 are done. I got everything finished there for my German translation.

The Rockman & Forte tool itself is not the problem. I can extract and insert original graphics just fine, even with AGTP's translation. Just edit the ROM Header at 0xFFC0 to ROCKMAN&FORTE and it works.

The problem with the tool is, if you edit a graphics file (e.g.grafico_c1e4ea (stage select symbol)) it turned out 20000 bytes larger for me as said before and it doesn't repoint the graphics anywhere resulting the game to load garbage.
When inserting umlauts to my German Rockman & Forte translation the file was 8 bytes or so smaller than the original so I had to actually copy the rest of the graphics back to their original location cause the tool did not repoint them..
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on June 07, 2017, 05:35:38 am
The Rockman & Forte tool itself is not the problem. I can extract and insert original graphics just fine, even with AGTP's translation. Just edit the ROM Header at 0xFFC0 to ROCKMAN&FORTE and it works.
The problem with the tool is, if you edit a graphics file (e.g.grafico_c1e4ea (stage select symbol)) it turned out 20000 bytes larger for me as said before and it doesn't repoint the graphics anywhere resulting the game to load garbage.

So you got it working? You just needed to have the graphics file the same size. That's normal. A lot of these roms and programs are very restrictive.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on June 07, 2017, 08:50:38 am
Yeah, except I had to change the graphics locations manually afterwards but it worked.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on June 08, 2017, 07:02:57 pm
Good to hear. Any plans to translate the Megaman X remake for the PSP? There's video in the game so you'd have to add subtitles.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on June 10, 2017, 02:56:54 am
No idea yet. Still working on Rockman & Forte in German. Got everything done, just missing like half of the entries in the database.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on June 22, 2017, 06:16:41 am
Looks pretty great! Saw the translations on the homepage of RHDN. I'm doing a Spanish translation of a videogame, but I've been pretty busy so haven't had much time to release another version with updated translations and fixes. Hopefully you had someone test it. It's easy to overlook something and have it buggy in the game.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on June 24, 2017, 04:03:20 am
I didn't have anyone testing the game but I played through the game mulitple times with Mega and with Bass.
However, if anyone actually finds problems, I won't mind updating it (assuming the person knows German well though) :P
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: azoreseuropa on June 24, 2017, 06:54:19 am
I didn't have anyone testing the game but I played through the game mulitple times with Mega and with Bass.
However, if anyone actually finds problems, I won't mind updating it (assuming the person knows German well though) :P

Hi. Yeah, you are using AGTP's version.

You should have notice that Title screen has a bug compare to SFC version. The splash is incorrect since SFC's splash is fine.

The title screen inset after selected the character is still in Japanese title screen.

And there is other bug in 100 DATA COLLECTION. Number 16 supposed to be WoodMan instead of WindMan and thats all.

You fix the discoloration in Title Screen! :)

I did mentioned that to AGTP about it. And he is aware of the problem and didn't say if he is looking into it just yet.

I can post the screenshot here if you want. However, I won't be back until tomorrow evening, thought.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on June 24, 2017, 12:52:32 pm
Hi,
I fixed the database with WoodMan <-> WindMan already before releasing my translation as well as many other things... If you tested my translation, please provide me the SRAM or Screenshots.
If you're talking about AGTP's translation, I'm not the person to contact with. ;)

Also, what do you mean wth incorrect splash? I don't see anything wrong with my fixed title screen at all. O_o

Yes, please post screenshots, IF it applies TO MY GERMAN translation.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: azoreseuropa on June 26, 2017, 08:11:25 am
Hi,
I fixed the database with WoodMan <-> WindMan already before releasing my translation as well as many other things... If you tested my translation, please provide me the SRAM or Screenshots.
If you're talking about AGTP's translation, I'm not the person to contact with. ;)

Also, what do you mean wth incorrect splash? I don't see anything wrong with my fixed title screen at all. O_o

Yes, please post screenshots, IF it applies TO MY GERMAN translation.

Yes, it applied TO YOUR GERMAN translation, of course. :)

LOL! I don't know what to called it but I use the word" Splash Title".

Splash Title Screen:

GERMAN:

(https://www.imageupload.co.uk/images/2017/06/26/RockmanForteJapanPatchGermany.000.png)

NO "K" LOGO on It!

ORIGINAL:

(https://www.imageupload.co.uk/images/2017/06/26/RockmanForteJapan.000.png)

An original "K" logo is there.

GERMAN:

(https://www.imageupload.co.uk/images/2017/06/26/RockmanForteJapanPatchGermany.004.png)

NO "K" logo on it while shooting.

ORIGINAL:

(https://www.imageupload.co.uk/images/2017/06/26/RockmanForteJapan.003.png)

An original "K" logo is there while shooting.

AGTP version has the same problem as yours.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ice Man on June 26, 2017, 01:00:33 pm
Oh, you mean that. I didn't find it problematic at all but I will check it on the weekend. Thanks for mentioning it. :)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: azoreseuropa on June 28, 2017, 03:39:18 pm
Oh, you mean that. I didn't find it problematic at all but I will check it on the weekend. Thanks for mentioning it. :)

You are welcome. Looking forward to your fix because I hope AGTP will fix it too and your version is actually AGTP version that I notice. ;)

Anther one for inset title untranslated:

(https://www.imageupload.co.uk/images/2017/06/28/RockmanForteJapanPatchGermany.000.png)

That's all.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on July 14, 2017, 04:05:34 pm
Mega Man Maker program.
https://mega-maker.com/about.html (https://mega-maker.com/about.html)

This basically mimmicks Mario Maker, but using classic 8-bit Megaman. I really like the idea for this, where you can just edit one level at a time using resources from MM1-6 or such, and then upload it to their servers. This is sort of what I wanted to do for Mega Ed X editor, when I saw it was closed source, and also what I've seen people do for level editors for the MMX series, using Game Maker, but most projects have only released teaser trailers and were abandoned most of the way through. It looks like this editor uses abilities up to MM4, so you can slide and you get a charge shot, but I don't see Rush or Beat anywhere in the samples played.

One of the setbacks for this program/editor is that it's mainly a rom hack so it doesn't really change the location in the rom where the graphics are stored, so if for example you want to edit stage 5 in MMX you have to use the resources for stage 5, unless you meticulously redraw each graphic for that stage, or copy/paste graphics from other stages/games. And if you only wanted to edit one stage for this game, rather than the entire 10 levels, because it's too big of a project to re-do it all, the game is still going to have all the original stages in there, the boss fight, and the long intro. So to even get to play your custom stage you will have to beat the long introduction scene, or enter a password to skip it all.

Also, one thing to note is that since it's a rom hack it requires the original rom so copyright issues are jeopardized for every fan that even wants to play that one stage that was edited, or who wants to edit that one stage, rather than these fan-made level designs that basically rip all the same material but do not require the original NES rom. It's also cool that there is a dedicated server, with a rating system for each level. I mean how many hacks are out there, where you have to manually apply all these patches, only to get a crummy game? Or where you just get a bunch of dead and broken links because someone uploaded their levels to geocities or wordpress then canceled their web hosting plan, or website so it's hard/impossible to find.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ness on July 15, 2017, 01:15:22 pm
I don't want to derail the thread, but since you started on this topic.. Everything you pointed out, like changing graphics or enemies etc can be done in romhacks.
Also nothing prevents you from releasing hacks consisting of just a few stages and even making sure only those new stages can be played. It takes more involvment through romhacking, but you'll simply have more control over everything.

Also the "copyrights issues" romhacks can have apply to MM Maker as well, except ten fold for them. For romhacks officialy you need the game, but not for MM Maker.

The advantage of something like MM Maker are that it's more userfriendly, faster, and that you have more enemies at your disposal (because importing enemy AI from one game to the other for a romhack isn't as simple as importing graphics), everything else you simply have more freedom with romhacking. Even something as simple as foreground graphics, in MM maker you can't manually choose and connect each single 16*16 block's graphics, the program does it automatically, leading to unfitting looking graphics everywhere (their example stages are full of it), also you can't make or modify your backgrounds either, etc etc

MM Maker is nice for what it is, but it doesn't replace romhacking (it doesn't aim to), and if anything I'm sure it'll bring more people to MM hacking because they'll want to edit the actual games and have freedom on all the little things and details.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on July 15, 2017, 06:59:13 pm
also you can't make or modify your backgrounds either, etc etc

I'm not really entirely sure how to edit backgrounds through MMX editor. They are disabled when you load the levels. So it doesn't surprise me, in MMX Generation, for example, that there is a solid purple background for the intro/highway stage. I'm working on a patch for the roms that will make it a little easier to test the game.

UPDATE:
I completed the patch over the weekend, specifically for this editor in mind. It's real simple it just skips over the introduction/highway stage and goes directly to the stage select screen like classic NES Megaman. I also included the assembly file with the instructions I used. So technically, if someone wanted they could have the game load directly into stage 3 for example, skipping the intro. This is useful if someone wanted to edit only one level with the Mega Ed X editor and thought it was pointless to load all the other junk. It can infinite loop on that level too. I just uploaded the rom hack today so it should be up on the site soon. So far it's only for MMX, but I have the address locations for MMX2 & X3 so I'll upload those next, after I create asm and patch files for those games.

I'll probably end up creating one or two levels for this game then, since it's a lot easier to just edit one level, than do all ten plus sigma stages and highway. Not sure if I will also hack the rom to give X some upgrades, plus one weapon, or have him just start out with the basics.

July 21, 2017, 02:34:53 am - (Auto Merged - Double Posts are not allowed before 7 days.)
Another thing I'm working on for the program, while I figure out how to get Undo done properly is I wanted to add the enemy names underneath the box, when in the event editor and the cursor has selected the enemy.

Example image:
(http://i.imgur.com/2nvWDBU.jpg)

Spiky is one of the better examples. I initially wanted to latch onto the GfxId variable, but it is grayed out many times when the box has selected an enemy. So for the majority of the images it will list the enemy name and no graphic. EventId is a unique variable name that is different for each enemy sprite. Most of the programming for this has been pretty straight-forward, just a few road-blocks. For the most part it's just grinding to add all the EventId's and Enemy names to separate arrays. I already have the highway stage complete, but there's approx 10 unique enemies on each stage for each game so that's 10 levels per game * 10 enemies * 3 games = approx 300 values OUCH!!

I'm going to upload a pre-compiled executable to github once I complete this part. This will include the other changes I made such as fixing Overdrive Ostrich compression in the layout, and a couple other levels that had bugs. I actually accidentally discovered how to use the program a little better. For example, the background for each stage is stored in TileSet Editor so you can edit the backgrounds there. I also was going to try and upload a how-to video on youtube approx 10-15 minutes long that shows how to use each part of the program, since some people have complained it's a little hard to understand how to use. That's all the updates for now. Thanks!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on July 23, 2017, 02:56:44 pm
That'll be awesome! Thank you for doing a few things on this editor! Every little bit helps IMMENSELY!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on July 23, 2017, 09:14:19 pm
Hi justin, thanks for the encouragement. Actually, that image I posted above is not accurate. As I've worked more with this caption stuff I realized type=2 is not actually an enemy. It's a trigger event that spawns the enemy in the next screen. type=3 means enemy, so the bounding box will be over the enemy in most cases, but it will not display the enemy in Event Editor window. The reason I want to do this is to make it more user-friendly. Unfortunately, many times in the editor it will not display the sprite of an enemy. At least if you have a text caption you will know, for example, this is where Utuboros spawns on Launch Octopus, without having to second guess by testing the game or watch someone play the level on youtube.

One cool little feature is the event editor also locks onto items, such as heart tanks, sub tanks, extra lives, and the capsules to upgrade X. Adding text is easy enough, but I'd really like to display the graphics for these objects (sans the capsules). Fortunately, the heart tank graphics are already done in X1&X2. X2 has the graphics for extra lives. I just need to find the address and palette information for the sub tanks. Although, I may just use a gif of those objects in the program. That would probably be a lot easier than trying to find addresses of all those things, re-arranging the tiles, and then having to match the palette.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Ness on July 24, 2017, 03:23:20 am
Using in-game graphics for those things is more complicated, but it has an advantage : if someone decides to change them, they'll appear changed in the editor as well.
For instance in MegaFLE X I was pleasantly surprised to find out that if you change the graphics of things like 1up etc, and even the default palette, the editor detects and shows that.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on July 25, 2017, 05:22:35 pm
Good suggestion, Ness. I hadn't thought of that. That will have to be something for after I add the info text to all the sprites and items. (I'm about 60% complete). I was briefly looking into that graphic, but for example there's 165 graphics for MMX2. And even after decompression many times the tiles are not arranged properly. That plus the fact I had no palette. I think I can manually copy/paste a palette in TLP so I could detect which graphic it is by color.

I also noticed that checkpoints have a unique ID I could add.

Yesterday/today I've been fiddling around with adding/removing enemies. I previously thought it was near impossible to move enemies from different levels, and tried editing the C++ to compensate, but you don't need to edit the C++ at all. You just have to adjust the palettes and make sure there are not too many enemies in one screen. I got this one to load about 90% correctly. If anyone else has had success with switching sprites around and knows what could be the issue let me know.
(http://i.imgur.com/KvdjlD4.png)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on July 25, 2017, 05:25:39 pm
Pretty much any enemy can be used anywhere as long as their ID is set and the levels VRAM setup for enemies gets changed. Not sure why it's not just independent with the enemy itself but it works I guess.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on July 26, 2017, 09:13:12 pm
(http://i.imgur.com/dOId6YO.gif)

The messed up graphic is part of the ball and chain. This is a snapshot of the VRAM from bsnes. I deleted two enemies on the screen, Spiky and Gun Volt, and replaced them with one Hoganmer. I only changed one value in the Event Editor window for the loading event, and left the rest as default.
VRAM location: 1000
Palette Offset: 3E -> 4 (changed from 3e for spiky to 4 for hoganmer)
Palette Slot: 40

I've experimented changing the VRAM location. Usually it just makes the sprite super buggy.
Update: I figured that Hoganmer was pulling some tiles/graphics from Gun Volt, but didn't know how to fix it. By changing the Hoganmer's VRAM slot to less than 1000 it screwed up X's sprite. I left his VRAM location to 1000 and changed Gun Volt's to 1650 and all the sprites loaded correctly. Took some fiddling with, because initially changing GV's VRAM to 1620 wasn't enough. I'm not sure what the max value for VRAM is. That would be helpful to know.

On a separate note I've found the graphic number,address info for the sub tank. I was having a lot of trouble finding that before. There's 3 values used for loading these items graphics: graphic number, palette number, and assembly number. Program is usually able to load palette fine from graphic, but you need to enter assembly number manually. I'm assuming this number is near the graphic pointer table somewhere. It's able to find this number no problem for enemy sprite graphics, but for these special items there must be a different algorithm. I can probably get that working in the next week.

 
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on July 27, 2017, 08:35:23 pm
There's two sections of VRAM for sprites.

X/Zero, health bars, weapon graphics, explosion graphics, health pellets, sub-weapon pellets, etc.. are in the first chunk of VRAM. Enemies use the entire 2nd chunk of VRAM so it's best if they stay there.

X1 and X2 might be different though. I know X2 sometimes used the first chunk with X/Zero and them for very small sprite objects or enemies at points, but generally the 2nd half was for enemies and objects only. X3 went with the method with the enemies strictly being in the 2nd half due to Zero being playable.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on July 28, 2017, 01:21:39 am
Yea, I saw Zero's VRAM tiles when messing around with values. I wonder if there's a way to change the sprites between X and Zero, without having to write new Assembly routines.

Anyways, looking through the project I saw that the collision editor works fine for Rockman&Forte, it just isn't loading up the graphics. I'm not sure how many values need to be changed so that it will load the majority of the enemy sprites. Maybe 7-10 address locations need to be swapped? 20? Anyways, I was thinking of looking into it as a little project after I finish this. Redguyy said he would check these forums periodically. He'd probably know more than me about it.

Any comments Redguyy?
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: andrewclunn on July 28, 2017, 02:02:48 am
Question, considering the on the fly loading of graphics into vram, would the possibility of holding level data in an external file and then accessing it via MSU-1 even be a remote possibility?
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on July 29, 2017, 04:15:13 pm
Question, considering the on the fly loading of graphics into vram, would the possibility of holding level data in an external file and then accessing it via MSU-1 even be a remote possibility?

Andrew, I'm not sure who you're asking, but I don't know how MSU-1 works. I've only seen videos on youtube of upgraded audio using MSU-1. As far as I know bsnes is the only emulator that even supports MSU-1. If you're looking to work with multiple files the layout (level data) can be decompressed in a giant directory of .bin files, using a separate program. But if you work with files that way the palettes aren't loaded in your tile editing software.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: andrewclunn on July 29, 2017, 09:05:54 pm
SNES9X has it in the dev branch.  I've been experimenting with loading game assets in Super Mario World from the MSU-1.  Sort of got ahead of myself.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on July 30, 2017, 09:09:13 am
(http://i.imgur.com/EfQ3w2f.gif) (http://i.imgur.com/L78xubS.gif)

I've just finished adding all the captions for sprites/objects for MMX1-X3 in the program. I've been testing the last couple days to try to get rid of any last-minute bugs. I have been making sure to get the correct enemy names off of wiki websites for these games. It includes rare enemies such as Batton M-501 in Armored Armadillo, and many of the chip upgrades in MMX3. It also gives info when the event editor locks onto a checkpoint, sub tank, weapon tank, energy tank, and extra life. The correct palette now loads for energy tanks in the game, and graphics show for weapon tank, sub tank, and extra life (except in MMX3).

Also included is the bug fix for Overdrive Ostrich during layout compression, which caused issues when saving. All the changes can be seen on github.

Source code:
https://github.com/rbrummett/megaedx_v1.2 (https://github.com/rbrummett/megaedx_v1.2)

Executable:
https://www.dropbox.com/s/p17cazs3t3352wv/MegaEdXv1.2.zip?dl=0 (https://www.dropbox.com/s/p17cazs3t3352wv/MegaEdXv1.2.zip?dl=0)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 09, 2017, 05:48:05 pm
Update:
I've been working on some changes for the last version I released. I'll call this new version v1.3.

v1.3 changes:
-When pressing arrow keys in dialog boxes it now changes value accordingly. (before it did the inverse, if you pressed up the value would go down and pressing down vice versa)
-Editor and Emulator Menu Items are no longer grayed out after opening a file
-mmx3 item graphics are now showing up in the editor. (heart tank, weapon tank, extra life, etc.)
-mmx3 ride armor module graphics show up correctly. also, the subtank for every game shows up properly. (before it was missing the bottom portion, re-arranged the tiles manually)
-the captions now change when you click on an object using your mouse with the event editor window open (previously they would only change via the prev event and next event buttons)

Dropbox binary/executable:
https://www.dropbox.com/s/rd06kokb7r0kyzr/megaedxv1.3.zip?dl=0 (https://www.dropbox.com/s/rd06kokb7r0kyzr/megaedxv1.3.zip?dl=0)
Github has been updated also

Comments:
I did look into making the undo function, and unexpectedly noticed it does save previous changes, in the bottom right box (but you have to manually re-click that and paste over your mistake). basically, the undo function would do that for you and save more than one command you could undo. Unfortunately, testing was difficult because dialog boxes are a pain to work with. I wanted to just press a key to test the undo function then change it to Ctrl-Z later, but key presses are disabled by default in dialog boxes. There's some horrible work-arounds that are ugly and I couldn't get any to work right. On a positive note, I did get the Undo() function to actually work otherwise. I just basically had it on a timer, so it would make all the changes then go back to the original after 3 seconds or so. So an Undo() function is definitely possible, it will just take some creative programming to get it to work how I want. Don't worry I also tested the game it uses the original graphics for the items, so just previewing them like this is not going to screw them up in the actual game during save. (I was worried about this for weapon tank and energy tank since it displays large versions during event editor window whether the item is actually large or small. although the caption will tell you if it's large or small).

If anyone is curious how I got the tiles to load for the graphics properly I basically just got an assemblyNum that displayed all the graphics, then arranged the tiles using xpos,x,ypos,y,and info manually. The problem was for subtanks and the ride armor module the letter was supposed to go on top of the bottom portion so   there was some initial problems because in order it would load-> top part of graphic, letter, bottom part of graphic, so the bottom portion was always on top of the letter. My work around was just load the graphic backwards. Unfortunately since it was in a for loop it went from 0 to #oftiles. Like an idiot I wrote a struct to change the for loop around so it resemebled this mess:

Code: [Select]
for (int i = start; loop.comparison(); loop.modify())
Then I wrote the struct functions to check a boolean value to see if the values should be reversed or not. I knew there was an easier way, but just couldn't think of it off the top of my head. Programmer's greatest weakness is being too impatient to brainstorm, and just immediately jumping in to code, rather than thinking things through. Later, I went back and deleted the struct and ugly for loop definition. All I needed was a separate counter variable.

Original:
Code: [Select]
auto map = baseMap + (tileCnt - i - 1) * 4;Edited:
Code: [Select]
map = baseMap + (tileCnt - counter - 1) * 4; //counter = tileCnt -1

Another bug I noticed, after spending maybe an hour or so searching for it was I accidentally had an if statement that was changing values instead of comparing them! Stupid compiler didn't even notice this error when compiling. Who uses an if statement to declare variables, DURING the conditional statement?
Code: [Select]
if (setvalue = wrongway)
if (compare2vars == correctway)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on August 09, 2017, 06:18:58 pm
Quote
load-> top part of graphic, letter, bottom part of graphic,

This is extremely unusual. The Ride Armor Chips are a 16x16 sprite (Or Tile depending on where it's loaded.) Sprite wise though, the whole icon loads all at once then the letter gets placed. For tiles though, it's actually all pre-set as tiles WITH the letters inside them. It almost sounds like the editor doesn't take into account about a sprite possibly being just one 16x16 sprite. (Though, Ride Chips have sprite assembly like every other sprite/object in game so that may be why it's not detecting things properly).
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 09, 2017, 07:26:44 pm
Even when the graphics are decompressed they are not displayed how they are in-game, they are split up into maybe 10 or so tiles, with E for subtank being one tile and each letter for the ride armor modules(h,k,f,r) being 1 tile. The sprites are assembled using two functions in RenderED.cpp- RenderEvent() and RenderObject(). Most of these sprites are assembled automatically through a C++ function that does pretty much what an emulator would do, using 3 values- gfxNum, palNum, and assemblyNum. All the addresses are known for these pointer tables so the program just picks them up as it goes along, except it's mainly for enemies, so far none of the items (type=0) have been able to properly load graphics based off these pointer tables, and you have to manually assign the correct values.

gfxNum and palNum are easy enough to find. assemblyNum has been a struggle to try and understand, and locate. For most of the items I've just been using trial and error. Check one value, see if it loads correctly, if not increase the value by 1 and check again. One person I talked to mentioned I should do a trace-log of the VRAM, in an emulator. Although, I eventually got the trace-log of the VRAM for a known graphic I couldn't figure out how the program got the assemblyNum, or how I'd find it for other graphics. (heart tank, gfxNum=0x36,assemblyNum=0x38). This would mean I probably wouldn't have to re-arrange the tiles manually, but after doing the trial&error method for 20-50 values I just gave up and did it manually. It all seems to work fine so I'm not to worried about it. Although, most of these instructions for tile assembly were added to a for loop it may cause some slow-down. I didn't notice any slow-down on my PC however. The mega ed x editor is pretty small and still under 1mb in total after compiling.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on August 12, 2017, 03:20:12 pm
Most of the VRAM is generally the same when it comes to enemy storage, though I know the game does use another routine where it'll shift the storage location of some enemy graphics in VRAM and even have that shift add onto the Sprite Assembly so it still assembles them properly in-game. I don't think this should ever be a problem to an extent since that routine tends to happen when you go back and forth between screen events as far as I can remember. (More-so when you're hitting a 'respawn' point and it redraws the VRAM graphics when there's a new enemy with new graphics on screen in the latter).

The base storage of everything in VRAM would be the right way to go and finding the location of the sprite assembly and animation data. Those will never have completely separate pointers as far as I know of, though some routines will shift the data accordingly when needed.

If there's ever a sprite editor implemented for X and Zero in the future, I have all the info needed for Sprite Assembly, Animation Data and VRAM setup. Only thing I don't fully understand in the animation data is some of the ending bytes as that will either tell another routine to do something or transition into another animation, though, I think that's handled OUTSIDE of the animation data itself so it's not too big of a deal.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 12, 2017, 04:04:19 pm
justin3009,
I know what you're talking about for the most part for the shifting. I've seen some special cases where Redguyyyy used if statements to get some bosses to load correctly. I wish I could get the item graphics to load as neatly as the enemy sprites. Here's the C++ for about 80% of the enemy sprites:
Code: [Select]
unsigned gfxNum = *(nmmx.rom + nmmx.pSpriteOffset[type] + ((id - 1) * (nmmx.type == 2 ? 5 : 2)) + 1);
unsigned assemblyNum = *(nmmx.rom + nmmx.pSpriteOffset[type] + ((id - 1) * (nmmx.type == 2 ? 5 : 2)));

As far as I can tell the address offset for the item graphics (type=0) is incorrect. pSpriteOffset[0] is set to  p_objOffset in another file. Here's how it's declared in MMXCore.cpp:
Code: [Select]
const long p_objOffset[4] = { 0x86DE9B, 0x86A34D, NULL, NULL };
Just a review of what the functions do that load the tiles in MMX:
for each tile there's 4 values- xpos, ypos, tile#, and info (whether the tile needs to be flipped or mirrored).
So basically if a graphic has 4 tiles there will be 16 values in hex at a certain offset. There's a pointer variable in the C++ that goes to the first set of hex values with these 4 variables. I guess I could just set a breakpoint jot down values for a known location, and then try searching in the VRAM trace log for these same values to try and get an idea what the algorithm is to load up the item graphics, or address offset (if it's different than objOffset). I'd definitely re-write the code if I could this way. It would be a lot cleaner, and easier to debug this way. Over the next week I'll try looking into it.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on August 12, 2017, 05:20:58 pm
Any items that enemies drop are always in VRAM at all times when in game. IE: Health capsules, weapon health capsules, explosions, lemon shot, etc.. the basics are always there

Ride chips, sub-tanks and heart tanks all have a different location in VRAM depending on the level. I'm not sure what entirely determines this but it might be like the other routines where it gets shifted depending on where it's needed. It's looking like it's the shifted graphic routine and stuff again.


From what I'm seeing in a trace thus far with Gravity Beetle
$00/B224 BD 23 86    LDA $8623,x[$08:86D7]   A:00B4 X:00B4 Y:0000 P:envmxdIzc ;I believe this loads the base location for various objects in the map to spawn.
$00/B227 AA          TAX                     A:043B X:00B4 Y:0000 P:envmxdIzc

$00/B22A BD 23 86    LDA $8623,x[$08:8A70]   A:0174 X:044D Y:0000 P:envMxdIzc ;This loads the heart-tank value of 36
$00/B22D C9 FF       CMP #$FF                A:0136 X:044D Y:0000 P:envMxdIzc

The base heart tank value is ALWAYS 36, which makes me believe it's the item to spawn in that location.

Each object, I think, maybe just item objects like this, are 6 bytes each though I'm not sure if this is all correct or not. This is what it APPEARED to be upon testing.
08:8A70 - Object graphics to use
08:8A71 - VRAM Location (2 bytes)
08:8A73 - Palette value to use (2 bytes?)
08:8A75 - Palette location in RAM to use (Doubles value so 70 here doubles into E0 which then in turn loads 7E:04E0 for the palette in RAM)


08:8A70 will load:
06:F732 (Base ROM location for compressed graphics?)  --> 06:F840 - Pointer to graphics for Heart Tank (2 bytes)
06:F732 (Base ROM location for compressed graphics?) --> 06:F842 - Bank of graphics for Heart Tank
06:F732 (Base ROM location for compressed graphics?) --> 06:F843 - How many bytes to decompress Heart Tank (2 bytes)
5 bytes for each object

Also, bit of RAM base location though I don't know all the bytes.

7E:0D18 - Base RAM location for enemies (+40 per enemy)
7E:1518 - Base RAM location for Item Objects (+30 per object)

$7E:1518 - Object active or not
$7E:1519 - What animation object is using?
$7E:151A - What event byte of object to load
$7E:151B - What sub-event object is on

$7E:1522 - What object is spawned

$7E:152B - Animation length of current animation frame
$7E:152C - Animation data pointer (2 bytes) (Not sure what determines this. Bank is $3F always)
$7E:152E - What sprite assembly to use
$7E:152F - Current animation frame
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 14, 2017, 07:51:03 pm
Thanks justin3009, this looks like it will be helpful. Two lines of significance:
1)
Code: [Select]
$00/B22A BD 23 86    LDA $8623,x[$08:8A70]   A:0174 X:044D Y:0000 P:envMxdIzc ;This loads the heart-tank value of 36Graphics number is well-known. You can see that in the event editor window + compression/decompression programs spit out all the addresses and sizes of each graphic in a txt file. I don't get why the accumulator value doesn't reflect that though. A:0174. Why is it not A:036, or A:054 (decimal)?

2)
Code: [Select]
$7E:152E - What sprite assembly to useThat address location in RAM is what I'm looking for. Pretty sure MegaEd X is not loading up artificial RAM, for the game, like an emulator would, so I'll have to try and find the sprite assembly in some memory bank. Unfortunately, it's hard to calculate because the program uses this 6mb rom variable that seems to change each time during run-time (maybe it is loading RAM?).

Code: [Select]
unsigned mapAddr = *LPDWORD(nmmx.rom + SNESCore::snes2pc(*LPDWORD(nmmx.rom + nmmx.pSpriteAssembly + assemblyNum * 3)) + frame);
LPBYTE baseMap = nmmx.rom + SNESCore::snes2pc(mapAddr);

Even if item graphics like the heart tank, are shifted to different locations in VRAM during gameplay you don't need to compensate for these offsets in the program. It just goes to the base location and loads up that graphic for each level where the graphic is used. It's not using VRAM to display them. I'll try and make sense of this over the next few days, along with the notes I already have.

Edit:
It looks like the game stores and updates the assembly number in that ram location ($7E:152E) during gameplay so I'm able to view it during emulation in bsnes. For the subtank (gfxnum 0x8c) I already had the correct value (assemblynum 0x96) by just guessing. When I published the first update I used that value. Nonetheless, it doesn't display the graphic correctly using that number (proof below), which is why I went to all the trouble to make it look better:
(http://i.imgur.com/joxWgD1.jpg)

For the ride armor modules the program only displays the top part of the graphic as well. For some reason it doesn't even load the tile used for bottom part. I've tried editing the frame #, size of the graphic, tileCnt variable, nothing seems to work to get the graphic to load properly. It's extremely peculiar and I've run out of ideas (except for manually loading each tile lol). Sorry for the small graphic, I think the bulletin board compresses and shrinks it, here's the full graphic for better understanding: http://i.imgur.com/joxWgD1.jpg (http://i.imgur.com/joxWgD1.jpg)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on August 15, 2017, 08:03:34 pm
Thanks justin3009, this looks like it will be helpful. Two lines of significance:
1)
Code: [Select]
$00/B22A BD 23 86    LDA $8623,x[$08:8A70]   A:0174 X:044D Y:0000 P:envMxdIzc ;This loads the heart-tank value of 36Graphics number is well-known. You can see that in the event editor window + compression/decompression programs spit out all the addresses and sizes of each graphic in a txt file. I don't get why the accumulator value doesn't reflect that though. A:0174. Why is it not A:036, or A:054 (decimal)?

For the first bit, it's actually loading the byte from there and the next command AFTER would show the byte since it's loaded then.

For the other though, that is exceptionally strange. It definitely sounds like it might be a sprite assembly issue then with how the editor is handling it. It's possible it's not layering things properly.

It looks like the basis might be correct there. The first number of the ENTIRE pointer to sprite assembly is how many chunks there are, then there's FOUR bytes to dictate each piece of sprite assembly. So essentially it goes:

Pointer to sprite assembly to use:

First byte before anything else: How many pieces of graphics to use for the sprite.

After it gets that, it starts loading 4 bytes per sprite piece.

First byte: Dictates rotation value and how big the sprite piece is. 00 is normal 20 is 16x16, 40 will flip it, etc..
Second byte: X coordinate
Third byte: Y coordinate
Fourth byte: What 8x8 or 16x16 to use in VRAM.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on August 15, 2017, 10:32:24 pm
Thanks justin3009, this looks like it will be helpful. Two lines of significance:
1)
Code: [Select]
$00/B22A BD 23 86    LDA $8623,x[$08:8A70]   A:0174 X:044D Y:0000 P:envMxdIzc ;This loads the heart-tank value of 36Graphics number is well-known. You can see that in the event editor window + compression/decompression programs spit out all the addresses and sizes of each graphic in a txt file. I don't get why the accumulator value doesn't reflect that though. A:0174. Why is it not A:036, or A:054 (decimal)?

That is because the accumulator gets updated on the next line, not the line with the LDA. Look at $00/B22D and it should have the 36 in the accumulator.


The image showing the messed up graphics for the energy tank looks like it's loading the tile data correctly. It looks like the graphics that are supposed to be in vram are messed up.
If you look at where the energy tanks graphics are stored in vram they are stored at $C800-$C8DF and at $CA00-$CA7F. The graphics that are supposed to be at $CA00 don't look like they got stored there. Maybe that part of the graphics isn't getting stored in the right location or not at all.  They might be getting stored after the 1st set of graphics at $C8E0 like how they are stored when the are decompressed which would be incorrect for loading the tiles to the screen.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 16, 2017, 12:28:38 am
Hi,
thank you both for the responses.


If you look at where the energy tanks graphics are stored in vram they are stored at $C800-$C8DF and at $CA00-$CA7F. The graphics that are supposed to be at $CA00 don't look like they got stored there. Maybe that part of the graphics isn't getting stored in the right location or not at all.  They might be getting stored after the 1st set of graphics at $C8E0 like how they are stored when the are decompressed which would be incorrect for loading the tiles to the screen.

I think this might be the case. Running the MegaEd X program through the debugger, and setting a breakpoint for the subtank assembly(fyi it's called a sub-tank in the X-series and E-tank in the classic series) I found it's only loading  5 tiles total (instead of the 7 required for the proper assembly). I tried just forcing the tileCnt to 7 instead of the 5 I know it's picking up from the pointer. That didn't work. Thinking caps please. How to fix?

Code: [Select]
GFXRLE(nmmx.rom, tram + current, SNESCore::snes2pc(addr), size, nmmx.type); //graphics decompression
nmmx.tile4bpp2raw(tram + (i << 5), nmmx.spriteCache + (i << 6)); //tile stuff
unsigned mapAddr = *LPDWORD(nmmx.rom + SNESCore::snes2pc(*LPDWORD(nmmx.rom + nmmx.pSpriteAssembly + assemblyNum * 3)) + frame); //pointer to sprite assembly
auto map = baseMap + (tileCnt - i - 1) * 4; //deeper pointer?
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on August 16, 2017, 01:30:01 am
The sub tanks do only have 5 tiles. 2 16x16 and 3 8x8.
Do you know if it's loading the data at $86:F4CD and $86:F4CF?

$86:F4CD 0E 60  //Used to store vram to $C800-$C8DF
$86:F4CF 08 E1  //Used to store vram to $CA00-CA7F
These are all v1.1 of mmx rom.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on August 16, 2017, 03:38:56 am
That's why I think it might be an issue with how the editor handles the sprite assembly. It doesn't seem to gather that it can load 16x16 tiles with the items and who knows what else.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 16, 2017, 04:03:46 am
What I meant was that it loads 5 tiles total.

It loads the first tile twice, (mirroring the tile when req'd)
then it loads the tile for the bottom curve twice,
and finally it loads the E.

It's missing that bottom portion that is loaded similarly to how the top of the graphic is loaded (with the blue part and the legs). I'm not sure about the VRAM thing, honestly I just learned about how to do a trace log so I wouldn't know where to check for values. I know for the first set of tiles it has x-pos and y-pos that are negative, how are those values even represented in hexadecimal? I'm assuming it would just be the two's compliment value in binary then converted to hex after.

Perhaps there's an issue in one of the functions that deals with the pointers and graphics before tiles are loaded (GFXRLE() or tile4bpp2raw()). My guess is with tile4bpp2raw. It's definitely able to detect if the tiles are 8x8 or 16x16, there's even a boolean variable that checks, based on a value in info. This info variable is an 8-bit bit flag that carries a lot of info about the tiles - whether to flip, mirror, and if it's big or small. But if for some reason that first value it picks up says to only load 5 chunks of data, rather than 7, maybe the program is going to the wrong address, based on the pointer. Or for some reason this graphic is actually 2 graphics split up and it loads up the first part, and then it's supposed to load the other part.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on August 16, 2017, 04:23:20 am
Can you post a image of the tiles that it is using to assemble
the sub tank? If it's the same image that shows up in the event editor than that's 100% the problem. The graphics do get split up and put in 2 different locations. The last 4 8x8 tiles are supposed to be under the 1st 4 8x8 tiles. Those last 4 8x8 tiles make up the bottom of the 16x16 tiles that get loaded to the screen. If they are not placed there the bottom of the 16x16 tiles will be empty.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 16, 2017, 04:48:08 am
slidelljohn,
Here's a link to some stuff with the subtank:
http://i.imgur.com/joxWgD1.jpg (http://i.imgur.com/joxWgD1.jpg)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on August 16, 2017, 04:58:06 am
That image of the tiles in the event editor is not correct.
The last 4 8x8 tiles need to be moved under the 1st 4 8x8 tiles
to complete the 16x16 tiles. Load up the mega man x rom and look at its vram for the sub tank and you will see how it is supposed to look.

I don't think the editor is loading this data:

$86:F4CD 0E 60  //Used to store vram to $C800-$C8DF
$86:F4CF 08 E1  //Used to store vram to $CA00-CA7F
These are all v1.1 of mmx rom.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 19, 2017, 05:20:17 pm
slidelljohn,
I'd like to keep the program as close to originally possible as I can. If for some reason the graphic is loaded up in 2 separate events, one that loads up the top portion, and another event for the remainder I can catch this by setting up a breakpoint and just stepping through, in bsnes. It will show a partially loaded graphic if this is the case, then a fully-loaded one.

I'll make sure to do a trace-log of the v1.1 so I get the same addresses.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on August 19, 2017, 08:05:36 pm
Yes I definitely agree to keep it as close to the original as possible but it still needs to work correctly.

If you want to see it just load the 1st part of the graphics in game set bit 0x80 at $86:F4CE (0x60 + 0x80 = 0xE0) and
it will only load the 1st part. That 0x80 is a bit flag to tell it to load another set of graphics or not to load another set. Look at the data below. The 0xE1 will make it not load any more into vram. After it checks the bit flag it will subtract 0x80 from it.
0xE1 - 0x80 = 0x61.

$86:F4CD 0E 60  //Used to store vram to $C800-$C8DF
$86:F4CF 08 E1  //Used to store vram to $CA00-CA7F

The 1st byte $86:F4CD 0E is how many bytes to dma into vram. The formula is 0x0E x 0x10 = 0xE0. The 0xE0 is the
amount of bytes to transfer. The 2nd byte $86:F4CE 60 is for
where in vram to store the graphics. (0x60 + 0x04) x 2 = 0xC8
Which would be vram location $C800. The 0x04 comes from the data in the event that loads the sub tank.

Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 20, 2017, 06:47:14 am
Alright, I checked what you said (changing value 0x60 to 0x80 in $86:f4ce). It loaded up some blinking thing, but it wasn't really the top part of the graphics like I expected. The editor decompresses the graphics before arranging the tiles, so it should reflect how it does in-game.

The size in the editor is 352 (or 160 in hex). Not sure why that is off. Should be 0109.

I'm going to have to find where the program jumps to for the tile map address variable, like for VRAM. It's based off the rom variable used in the editor so doesn't give an exact address when debugging. I think I should study a little bit more also. I'm not exactly sure how data is loaded from the rom, to VRAM, using DMA and offsets, so reading a guide will help visualize what exactly is going in hex/assembly mode.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on August 20, 2017, 07:10:15 am
Alright, I checked what you said (changing value 0x60 to 0x80 in $86:f4ce).

Should be 0xE0 not 0x80. (0x60 + 0x80 = 0xE0)

The size 0x160 seems to be right for the sub tank. The 1st
part is 0xE0 in size and the 2nd part is 0x80 in size.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 20, 2017, 07:44:34 pm
Hey that's great! By changing it to 0xE0 it looks exactly how it does in the editor. That's a good clue as to how to fix it. Only problem is I see it's directly copied from the rom in bank 86, and 0x60 is hard-coded there, so it should recognize to fully load the entire graphic.

Also, were these instructions directly before the subtank is loaded in the ram @ 7E152E? I need to find the something similar for the ride armor module graphics, that are having a similar problem loading.

Thanks for the help!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: protorock on August 21, 2017, 08:40:11 am
I have used the editor, works pretty good i cant replace bosses.Example boomerang kuwanger with vile in sigma castle 1.

that is actually the only problem i have ran into
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 21, 2017, 05:26:18 pm
@protorock, are you the main hacker for protoman 21xx? I saw a demo looks pretty cool. They actually changed the stages also, not just the palettes and sprites.

Can I ask what happens when you change the bosses around? I've only swapped around a few enemies, and I had to change the VRAM to do it. I think you would have to hack the assembly also, because each boss has a weapon weakness, and gives you a weapon after defeated. Not sure if that's copied when you change bosses. Plus, for Vile in Sigma stage there's a giant event revolving around that fight, that influences a small cutscene with Zero and enables large blocks of text.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on August 22, 2017, 08:58:29 pm
Hey that's great! By changing it to 0xE0 it looks exactly how it does in the editor. That's a good clue as to how to fix it. Only problem is I see it's directly copied from the rom in bank 86, and 0x60 is hard-coded there, so it should recognize to fully load the entire graphic.

Also, were these instructions directly before the subtank is loaded in the ram @ 7E152E? I need to find the something similar for the ride armor module graphics, that are having a similar problem loading.

Thanks for the help!

Yes it's loaded before $7E:152E ($7E:162E in spark mandrill stage) but not directly before. This is loaded when the level first loads. $86:b4de-$86:b4fb is the data for the sprite graphics in vram.

I could look at the source code and probably fix it. Can you post the function that loads the graphics?

Also can you post a picture of the ride armor module graphics that are messed up like you did with the sub tank?
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 22, 2017, 10:21:35 pm
https://pastebin.com/70tf3UkK (https://pastebin.com/70tf3UkK)

Scroll down to where it says //subtank @line 147. That inserts the values 0x96, later used as an address offset to load the graphic in RenderObject.
@line 206, it loads the correct palette, and other stuff that I've commented out to manually load the tiles.
There's more stuff below a giant nested for loop, where it's loaded onto the screen. That's also commented out. If you have any questions let me know.

I'll try and post a photo of the armor module graphic later.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on August 23, 2017, 07:13:23 am
It looks like line 261 is where it decompresses the image.
Are the lines at 263-266 the code that converts the decompressed graphics to a pc image? If so, then I think
at line 268 it needs the extra code to reposition the tiles
for how they are loaded into vram.

In mmx3 the level with the F ride armor module standing under the stairs delete (00's) all of the vram at $FE00-$FFFF.
Then look at the module and it should look like how it does in the editor. If you die the graphics should load normal again. Now delete the same vram that you just deleted and change the value at $08:DAC0 (60) to E0 and die and the graphics should still be messed up like how the are in the editor. I haven't seen what the messed up graphics look like in the editor but it should look the same.

This is the data that repositions the decompressed
module graphics into vram:
$08:DABF-$08:DAC0 10 60 1st part
$08:DAC1-$08:DAC2 10 E1 2nd part
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 23, 2017, 05:37:36 pm
I think you understand the graphics for the most part, except you wouldn't want to change anything at line 268 (that's palettes/color junk). If anything there should be another shift or offset to load the second set of graphics for the subtank (probably needs to be loaded separately, not sure if it's possible to load them both at the same time). Maybe there's a way to add the second set of graphics before tile4bpp2raw is executed.

here's the definition of gfxrle:
Code: [Select]
int GFXRLE(BYTE* rom, BYTE *dest, int pointer, int size, int type, bool obj)
so if gfxrle is ran twice with rom + 0x400, tram + size of first set of graphics, new size, etc. as parameters maybe it will load into "tram" the entire graphic so that tile4bpp2raw is able to pick up those last 2 tiles. Or maybe adding an offset to the pointer variable will get to the location for the second set of graphics.

However, if you scroll down the program, for example, many shifts and offsets are done after tile4bb2raw and mapAddr is initialized.

Code: [Select]
if (nmmx.type == 2) {
                // temporary fix for the boss sprites that have assembly information that is off by 0x20 or 0x40.
                tile -= (assemblyNum == 0x61 || assemblyNum == 0x92) ? 0x20 :
                    (assemblyNum == 0x68 || assemblyNum == 0x79 || assemblyNum == 0xae) ? 0x40 :
                    0x0;
                tile &= 0xFF;

This may not work for work for the subtank though, since "tile" is an unsigned variable and the tiles range from 0-6.

(http://i.imgur.com/Z7J5jBw.jpg)

As you can see with the photo, even the Maverick Hunter Bit/Byte in the sub-boss room below doesn't load 100% correctly. Probably about 80-95% of the sprites load correctly in the editor. Mainly sub-bosses and bosses have trouble loading correctly. I've been meaning to make a list of all the broken sprites. It's not a huge bug though, as long as people understand just because the sprite isn't assembled in the editor correctly, doesn't mean it won't run fine in an emulator/flash cart.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on August 25, 2017, 09:55:20 am
Heya there. Just so you know, your work is really appreciated! I've been taking a break from my MMX mod, I decide to check out RHDN, and suddenly there's fresh work on the editor! I helped redguy test i when he updated it, so I'm familiar with most of the quirks it had at the moment.

I only made a stage so far (I like having the intro stage to introduce design elements here and there). So, if you have any doubts about some things work in the editor, feel free to ask me (I don't know any programming, I'm just a tester / user).
Mod for you guys to see: http://ngplus.net/index.php?/files/file/17-mega-man-x-new-hard-type-wip-alpha-release/

I'm active at NG+, not so much here:
http://ngplus.net/

Thanks for all of your work on it! The idea is to make three mods in total, one for each of the SNES MMXs.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on August 26, 2017, 12:10:02 pm
Just a heads up, might be good to cap the 'enemy' value per game (IE: How many enemies, objects there are and what not)

Just found out in X3 the values range from 00-6B for enemy data in stages, but this includes various objects such as the platforms, elevators and such I believe as well. There's enough data setup for 535 bytes, 107 enemies in stage data that are 5 bytes each starting at:

86:E28E and ending at 86:E4A5

Most of this data may already be known and probably already in the editor, but doesn't hurt to bring it up for a bit later.

Code: [Select]
$02/E17F BD 90 E2    LDA $E290,x[$06:xxxx]   A:xxxx X:xxxx Y:00DA P:envMxdIzc ;Load how damage enemy deals to X/Zero when colliding
$02/E182 85 26       STA $26    [$00:0D3E]   A:xxxx X:xxxx Y:00DA P:envMxdIzc
$02/E184 BD 91 E2    LDA $E291,x[$06:xxxx]   A:xxxx X:xxxx Y:00DA P:envMxdIzc ;Load how much life enemy has
$02/E187 85 27       STA $27    [$00:0D3F]   A:xxxxX:xxxx Y:00DA P:eNvMxdIzc
$02/E189 BD 92 E2    LDA $E292,x[$06:xxxx]   A:xxxx X:xxxx Y:00DA P:eNvMxdIzc ;Load damage table single-byte value to use (Loads other pointers based on this value)
$02/E18C 85 28       STA $28    [$00:0D40]   A:xxxx X:xxxx Y:00DA P:envMxdIzc
$02/E18E BD 8E E2    LDA $E28E,x[$06:xxxx]   A:xxxx X:xxxx Y:00DA P:envMxdIzc ;Load which enemy to use (May be graphical data and animation data not entirely certain)
$02/E191 85 16       STA $16    [$00:0D2E]   A:xxxx X:xxxx Y:00DA P:envMxdIzc
$02/E193 BD 8F E2    LDA $E28F,x[$06:xxxx]   A:xxxx X:xxxx Y:00DA P:envMxdIzc ;Load sprite assembly for enemy? (Not entirely sure on this either)

Gets a bit confusing because there's data for 00-6B for them in stages, but the graphical values which I ASSUME 06:E28E is goes way beyond that.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on August 27, 2017, 03:43:21 pm
So, trying the altest version posted, I had to whitelist the file because it was reported as malicious by avast. After I do that, I try to open MegaEd X and message pops saying MSVCP140D.dll, VCRUNTIME140D.dll and ucrtbased.dll are missing.

Previous versions of MegaEd X work fine. Anything I'm missing?
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on August 30, 2017, 09:55:11 pm
HartHunt:
Yes,
it seems you're missing some run-time libraries. Please make sure you're running the latest version of Visual Studio. If you're trying to compile it yourself, it seems to work in v2015. I'm not sure why Avast is giving you that error. I virus-scanned it myself with my anti-virus and it's fine. If you're worried about malware the open-source is available on github. You can always download and compile it yourself. Maybe just copying and pasting the executable from the debug directory is the wrong thing to do? You may need to install .NET. When I downloaded the version from Redguyyyy I just needed that retro.dll and it worked fine.

Also,
thanks to everyone who is supporting this site with donations.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on September 11, 2017, 11:09:56 am
Thank you! I'll try updating Visual Studio and see if that works. Yeah, it was more about letting you know that Avast didn't like the file. It can happen with executible files. I'll update the post later.

Update:
After updating Visual studio, it throws the error "The application was unable to start correctly (0xc00007b)". It seemed strange, so I tried to compile the source code. I couldn't get it to work that way either. I'm running Windows 10 64.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on September 13, 2017, 04:00:29 pm
@Hart-Hunt,
Reading through several forum posts in MSDN, and other sites, here's what I got:
"Error 0xc000007b is commonly caused by mixing up 32-bit and 64-bit libraries. "

This program was written before 64-bit architecture. There's probably some mix-up in the dll files. Some people suggest the easiest solution is to re-install Visual Studio, .NET, or Direct X.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on September 15, 2017, 03:30:10 pm
Nope, that's not the solution, I tried that before posting. VS is definitely up to date. One can't also compile the source code with the latest VS. Lastly, also before posting, I had other users also try to use the 1.3 .exe and also compiled it. Which version of Visual Studio did you use? There's definitely something missing on your end.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on September 15, 2017, 04:39:02 pm
Well it compiles and runs fine on my PC.

Some specs:
Windows 10 64-bit

Microsoft Visual Studio Community 2015
Version 14.0.23107.0 D14REL
Microsoft .NET Framework
Version 4.7.02046

Installed Version: Community

Visual Basic 2015   00322-20000-00000-AA649
Microsoft Visual Basic 2015

Visual C# 2015   00322-20000-00000-AA649
Microsoft Visual C# 2015

Visual C++ 2015   00322-20000-00000-AA649
Microsoft Visual C++ 2015

Application Insights Tools for Visual Studio Package   1.0
Application Insights Tools for Visual Studio

ASP.NET and Web Tools   14.0.20626.0
ASP.NET and Web Tools

ASP.NET Web Frameworks and Tools 2013   5.2.30624.0
For additional information, visit http://www.asp.net/

Common Azure Tools   1.5
Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.

GenerateUnitTest   1.0
Generates unit test code for methods in classes under test.

Microsoft Azure Mobile Services Tools   1.4
Microsoft Azure Mobile Services Tools

NuGet Package Manager   3.0.0
NuGet Package Manager in Visual Studio. For more information about NuGet, visit http://docs.nuget.org/.

PreEmptive Analytics Visualizer   1.2
Microsoft Visual Studio extension to visualize aggregated summaries from the PreEmptive Analytics product.

SQL Server Data Tools   14.0.50616.0
Microsoft SQL Server Data Tools
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on September 25, 2017, 04:43:55 pm
Someone contacted me about potentially creating an editor for MM7. I wanted to go ahead and further expand R&F,M&B to include the enemy sprites in the editor first. (already includes layout). If justin3009/slidelljohn wanted to help that would be great. (i think pausing finding correct graphics for subtank/ride armor module for now is acceptable. the work-around still functions even if it's not efficient).

So save your energy to help work on this! More important than efficient method to get subtank/ride armor module graphics. Even though, R&F is typically poorly reviewed, and wasn't even officially released in N. America...

I'll be searching in the next week or so, for RAM address locations for assembly info, palette number, event id number, and graphics number.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on November 11, 2017, 08:23:16 pm
Quick question for anyone who uses this editor.

I'm trying to modify a level in X3 by basically altering a Camera Event. I've noticed that it looks like these camera locking events have a certain 'block' that they attach to to designate some scrolling stuff (Or so it appears?) Is there any actual way to move those blocks?

Also, looks like updating the 'X' position doesn't seem to display properly on the editor unless you go to the next event and then go back to the one you were on.

Edit: Rather, does anyone know how to properly move a camera event to a different location on the same map and NOT have it bork everything? I have all the coordinates set and moved but it still triggers in the absolutely wrong spot no matter what I do.

Edit 2: I was able to manage to get the camera events to spawn in a new area (Hopefully I didn't break anything else doing so). But I had to use BOTH Mega Man X3 level editors to get this to work. MegaED X does not allow the moving of spawn lines nor does it allow the moving of objects from one spawn line to another.

The other MMX3 editor allows you to MOVE the spawn lines but I cannot move one object from a spawn line to another. So I just removed two mine tortoise's in Toxic Seahorse's level to get the camera events to work and moved one spawn line closer to another for it to work.

The biggest issue I'm seeing with the 2nd editor is that you cannot move objects to a different spawn line. There's some that are COMPLETELY blank but cannot be used, which is frustrating as it'd help a lot. I can only ascertain that this is data that has not been uncovered yet.



Update
So, it turns out MegaED X isn't prescribing all the variables correctly for the Camera Locking events.

It has most of the actual data correct but there's an extra.. I think 2-3 bytes AFTER the data that designates more on the camera locking.

Camera Lock Offset 47 at 03:DF7F (03:E40A):
A0 0B (Left)
30 0B (Right)
D0 05 (Bottom)
C0 05 (Top)
47 (Lock Offset)
30 (Lock Camera #1)
--> Setting to 00 will allow the camera to move left and right
--> Setting to 20 will allow the camera to move right, but not left
--> Setting to 30 will not allow the camera to move left or right
20 (Lock Camera #2)

The Lock Camera #1/#2 data is NOT modifable anywhere in MegaED X and this is absolutely necessary for full control of how the cameras work.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on November 25, 2017, 09:23:39 pm
Hi Justin,
Amazing work as always, if you were using the MegaEd X Editor from me, or RedGuyyy, or the original programmer please let me know. I'd like to update the files you made changes to (then update the github).

I've recently been running the debugger in Bsnes, trying to get address locations for assembly number, palette number, and event information in the RAM for Rockman&Forte. I have the program that spits out all the pointer table info for graphics and such, so should be able to grab that. Hopefully, I could get the editor working for MM: Rockman & Forte. Despite, it's non-north american release, it was a fun game, nearly on par with MM8. Once I'm able to get this info I may be able to make a stand-alone editor for MM7 (and be the first one to do so!!), before even the pathetic and lazy hackers working on MM: Wily Wars (4-6).

(On a side note, Rockman&Forte, or Megaman & Bass as has been also known, while difficult, at least has save states, unlike it's previous SNES Megaman titles. You cannot return to the store and purchase items for boss battles, like MM8. MM7 has been long overdue for an editor. While there's probably less than 10 hacks for 16-bit MM games, there's 0 for MM classic games [i.e.: non MMX games]. Also, side-side note I had recently played through MMX3, which I previously abandoned for MMX1-2 and the classic series. I actually enjoy the game quite a lot, it allows ride-armor, and the equipment perks are quite nice, plus the gold armor, and Vile boss fights make the game quite challenging.)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on November 25, 2017, 11:01:22 pm
I was using Redguy's I think. Though even the original and yours have the same issue as well. No biggy there really.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on November 26, 2017, 01:19:45 pm
Hey there. Sorry for the long absense. I've just migrated from W10 to W7. At the time, I couldn't really find the download for the version you had of VStudio 2015 (I had 2017 and didn't work, no matter what I did). I'll try now.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on November 26, 2017, 06:24:33 pm
I'm trying to modify a level in X3 by basically altering a Camera Event. I've noticed that it looks like these camera locking events have a certain 'block' that they attach to to designate some scrolling stuff (Or so it appears?) Is there any actual way to move those blocks?

I'm not exactly sure what you're trying to do. Are you using the checkpoint editor, or the event editor? Are you working with a type=1 event, or since you mentioned sprite spawning I'm assuming type=3? Looks like you were able to work around it.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on November 26, 2017, 06:40:47 pm
Each camera event looks like it's locked into a certain area of each level. They're all shared so modifying one will modify the other of another level. So their coordinates and such are designated into that slot. The issue is that the camera events NEED to be on the same spawn lines where you want them, as for anything else actually. MegaED X doesn't allow modifying the spawn lines or their locations so it makes it impossible to edit normally.

The Japanese MMX3 level editor lets you modify the spawn lines but doesn't let you modify the camera data itself so both editors had to be used. I had to drop the entire idea anyway that I had since I realized after the fact that you can't draw a text box underwater due to how the HDMA is handled.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on November 29, 2017, 11:07:40 am
Iirc, expanding the rom allows you to have independent camera events per stage. The event in X1 was type 2, id 0, and then you specify the subID you want.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on November 29, 2017, 11:51:55 am
Expanding seemed to break X3 quite badly. Even then though, not being able to move, add or remove stuff on the spawn lines makes it super hard to modify the level. Unless I'm missing something.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on November 29, 2017, 01:33:31 pm
Here's some feedback!

About the changes that I've noticed.
1) The emulator doesn't allow for save or load stating.
  a) When configuring the controller for the emu, the save and load state don't recognize any keys
  b) When pressing F2 to save and F4 to load (defualt keys in 1.2), MegaED X crashes.
2) Having the individual editors (Layout editor, Scene editor, Block editor, Tile editor, etc.) as separate windows from the main MegaED X window is actually a lot less comfortable to work with, because in 1.2 I'd be able to look at all of those editors at once and make sense of what I'm doing. I'd be a lot more comfortable to work with if it was reverted to 1.2.

Asides from that, at least in X1, the changes didn't really help me at all. I'm using 1.2 because those changes either made the editor crash or made it more uncomfortable to work with.

For features that'd actually help a ton, I'd suggest looking up the events in Megaman X, and adding a field to change all of the routines that are not included in the editor. For example, changing the event that's in the editor that makes each Dr. Light capsule appear doesn't do anything unless you also change the spawn location of the capsule, which is located in another table. There's many things like that. There's the falling floor in the intro stage that has another table, there's the gas tubes in Storm Eagle's stage, the platforms in Sigma Stage 1. Then there's also the tiles that change in custom events. All of those one has to debug their locations as well. Examples of this are the glass breaking in Storm Eagle, the ship breaking and the platforms it leaves after that, the floor that changes in Flame Mammoth's fight.

Another feature to add would be to replace the archaic event editor, with something that actually names the events by name. Right now, to add a spikey, you need to add a type 3, ID 15, subID 0 enemy. I only know this by memory because I've done it so much, but there's no way I could remember each single one. I need to help myself with an Enemy ID list.

Similar example comes with the event editor as well, with the 2, 15, X events, the ones that are a purple line that allow you to change which graphics are loaded. I have to be listing the vram memory each one takes, and the palette memory eac one takes, along with each's palette and gfx id. It's archaic to say the least. Changing that is a pain.

Hope the feedback helps! I constantly use the editor (I had a bit of a hiatus because of school, but I'm actually streaming at my twitch channel the development of my mod, so people can check that out anytime). So if you make any changes, I'll be happy to test them and report back to you.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on November 30, 2017, 08:13:50 pm
Hi thanks for testing the program. As far as the error you got in VS 2017 I'll have to ask the MSDN forums, because you said VS 2015 doesn't give any issues.

The reason I added the minimize buttons is because they were not set as child windows, so many times when using the editor I'd have the main window minimized and I'd be in a web browser with all these dialog boxes on top of the browser in the way with no way to move them, except closing.

I've taken your notes on the event editor, and those are definitely some good suggestions for making it more user-friendly. Here is a mock-up I made this afternoon below. (I also plan to add a similar drop-list for switching items, and the buttons will be grayed out when not in the correct Type to prevent errors).

(https://i.imgur.com/VerbSp8.jpg)

I wish I understood how to calculate the VRAM in this program better (which may or may not differ from true VRAM in an emulator). Right now I have switched enemies and got it to properly work in an emulator, but it took a lot of tweaking from the VRAM slot to get the enemy to properly show up in an emulator. I assume it has to do with the size of the sprite (8x8, 16x16, or 32x32). However I'm not going to be able to correctly change those values until I understand it better (right now it's trial&error). Yes, the palette offset is important too. I may be able to override the values in the editor window, but typically it's set during a previous event (the purple line where graphics are loaded).

As for special routines/sprites such as gas tank in Storm Eagle. That will have to wait also. I don't fully understand how to separate these into separate stages, and have not tested it myself yet.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on December 01, 2017, 08:41:17 am
Yeah, if you ever need my specs let me know. Basically, 1.3 didn't work with W10, VS Community 2017. I was "forced" by W10 to downgrade to W7 (same PC), and I was able to find the same version of VS2015 you had. I installed that version and 1.3 ran fine.

Yeah, the "always on top" 'feature' of 1.2 (as they're not child windows as you correctly describe), is actually helfpul and even necessary when designing stages, because one needs to constantly compare the tiles between the editors, and if you are running some other program at the same time, then the child windows will minimize and you'll have to manually click on them in the task bar everytime. This happened to me a lot when streaming. Also, there was something that happens with my computer, I'm not sure if it's because of the resolution (1980x1080), but basically the location of the texts and boxes in the editors get all messed up. So the text that goes next to each box gets offset and it becomes a pain, even unusable unless you know what each box does from before like my case.

Here's a picture. Happened with W10, happens in W7, in both 1.2 and 1.3. https://i.imgur.com/1m9YVat.png

The mock up is kind of getting close to it. I'd have three boxes:
- First one for the type of event: Enemy, Item, "Level Specific Events" (including Camera Locks, Graphic Loads, Palette Loads), Items and Upgrades, and Misc.
- Second one for the actual event: For enemies, Gun Volt, Spikey, Flamminger, Spark Mandrill, Vile, etc. For Items, 1-Up, HP, Ammo, etc.  For Level Specific Events, Camera Locks, Graphic Loads, Palette Loads, Background changes, etc. For Items and Upgrades, you have items, like 1-Ups, HP, Ammo, and upgrades, like SubTanks, Heart Tanks, Capsules. For Misc, you have other events, like Boss doors, floor falling in the intro stage of X1, explosion from gas tubes in Storm Eagle, Igloos from Chill Penguin, hopefully you see what I mean with that.

If you need any help with the VRAM, I know how to load enemies with trial and error. Basically, each enemy needs a certain amount of VRAM, and you need to set a portion of the memory to it, all specified in GfxID in the editor. I don't have the values right now, but some enemies might need 200 bytes, while others like bosses need a lot more, which is why bosses for example can't spawn with many other enemies without messing things up.

If you need help with figuring out how some things work, I have a lot of knowledge, mostly from trial and error, and I know where many tables are located, because I changed them for Hard Type.

Also, to note, I'm simply writing down all that I can think of, but yeah, you already even considering doing one of the above changes is great, and I really, really appreciate it. And you'd do well to do what you say, take things slow and do one concrete change at a time.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on December 01, 2017, 07:02:15 pm
You may not need to downgrade to run the program. There's a redistributable package that installs the run-time components of programs made in C++ from VS 2015. (Just a small 1mb file). That way you won't need to install VS 2015. (if you'd like to test plz let me know if it works).
https://www.microsoft.com/en-US/download/details.aspx?id=48145 (https://www.microsoft.com/en-US/download/details.aspx?id=48145)

Yea if you could give me some insight into how VRAM works I could better understand how to allocate memory correctly to load in the graphics, that would help a lot with switching enemies throughout the program. I'm assuming that there's two sizes for enemies- large and small. For example, when swapping in Hoganmer on the first stage I set the VRAM to 1000. I had to change the VRAM slot for the next enemy from 1600 to 1650, otherwise Hoganmer didn't load correctly. So Hoganmer's graphics needed between 600-650 units to assemble. Yet, the sprite I swapped him with only needed 600 units or less. Sub-bosses and bosses are going to be excluded. Gigantic Mechaniloid CF-0 and Utoborus would be tedious to program their special routines. (I just spent the last few days figuring out how to move Chill Penguin to another stage. His ice shots are a separate graphic, not included when you pre-load C.P.).

For Misc. (Boss doors, floor falling in the intro stage of X1, explosion from gas tubes in Storm Eagle, Igloos from Chill Penguin) did you say you have to edit these events more than just changing the event Id, gfx Id, and palette? I have not worked with these, but some are labeled.

Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on December 01, 2017, 07:49:52 pm
You may not need to downgrade to run the program. There's a redistributable package that installs the run-time components of programs made in C++ from VS 2015. (Just a small 1mb file). That way you won't need to install VS 2015. (if you'd like to test plz let me know if it works).
https://www.microsoft.com/en-US/download/details.aspx?id=48145 (https://www.microsoft.com/en-US/download/details.aspx?id=48145)

Yea if you could give me some insight into how VRAM works I could better understand how to allocate memory correctly to load in the graphics, that would help a lot with switching enemies throughout the program. I'm assuming that there's two sizes for enemies- large and small. For example, when swapping in Hoganmer on the first stage I set the VRAM to 1000. I had to change the VRAM slot for the next enemy from 1600 to 1650, otherwise Hoganmer didn't load correctly. So Hoganmer's graphics needed between 600-650 units to assemble. Yet, the sprite I swapped him with only needed 600 units or less. Sub-bosses and bosses are going to be excluded. Gigantic Mechaniloid CF-0 and Utoborus would be tedious to program their special routines. (I just spent the last few days figuring out how to move Chill Penguin to another stage. His ice shots are a separate graphic, not included when you pre-load C.P.).

For Misc. (Boss doors, floor falling in the intro stage of X1, explosion from gas tubes in Storm Eagle, Igloos from Chill Penguin) did you say you have to edit these events more than just changing the event Id, gfx Id, and palette? I have not worked with these, but some are labeled.
I already installed VS 2015 in my freshly installed W7, so no worries. And so I won't be able to test that download as well. :P

Well, what I've figured is that each enemy needs a certain amount of VRAM, placed within $1000 and 1FFF, and the way one can tell how much it's used is by going to the next enemy loaded in vanilla and subtracting the numbers. That way, Hoganmer takes 700 VRAM, Flamminger takes 700 VRAM, and then there are enemies with lighter graphics: Turn Cannon takes 200 VRAM, Bats take 300 VRAM, Mets take 300 VRAM. One can easily pick a combination of enemies that add up to $1000 VRAM, and add put them all in. That's what I did in New Hard Type, and it works really well. The VRAM addresses below 1000 do other things like store X's graphics and whatnot, but somehow, vanilla will use address 400 in some ocasions. I haven't been able to figure out how or why.

About the misc events, it highly depends on the event. Many of them will load from a table that will set the location of the tiles that will be changed, and from another table that will set which tiles are getting inserted in the tile map. Doors for example have like 4 sets of tiles that need to be specified. Gas Tubes have the tiles that go after they get destroyed, and so on. I can find the replacing tiles with a debugger, but actually documenting the code is beyond my capabilities, which is why an editor would simplify this so much for me and other users.

About the VRAM, gfx, I document each enemy ID with those whenever I use them. So it's not complete: https://pastebin.com/WxBGLzhQ
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on December 01, 2017, 08:23:09 pm
X1 and X2 will sometimes use 400 for very small enemies or effects. X3 will never store there as it's reserved entirely between X and Zero.

As for the tile replacement on some destructible objects, yeah that's very hard coded. It'd be a lot easier if there was some way to automatically designate where the tiles would appear based on the X/Y coordinates of the destructible object itself rather than using a hard table. It'd make it a lot more customizable, but that's probably not possible without some hefty calculations.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on December 03, 2017, 07:52:35 pm
Yes, for example, the ice shots for Chill Penguin are set at VRAM slot 400 during gameplay. I wonder if there's a place in the rom where VRAM size is stored. In the graphics pointer table the size of Hoganmer, for example, is 00 20 (2000 bytes). Yet in-game it's 0x700. Maybe the size is stored as decimal, but later read as hex? 2000 in decimal is 0x7D0, but I know in hex the size is actually closer to 0x650. Most important values already have variables so it will be easy to make a struct, or vector array.

Megaman Fanga:
On their 30th anniversary livestream Capcom Unity announced MM11 will be released late 2018, and the X collection will be ported over to the Switch along with the classics collection.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: SOPHIA on December 10, 2017, 07:02:56 am
Nice to meet you
I am Hack Rom creator of Rockman X
I made a work called Rockman X Generation
I am using this editor well, so I am looking forward to the update
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on December 10, 2017, 10:01:02 am
For any time there's graphics stored, the location in VRAM is 'RIGHT' next to it in data. It's all in one giant table. Uncompressed and compressed graphics both have their own set of stuff but their VRAM storage location, ROM graphic location and what not are always side by side. The game will call it when it's needed based on the 'spawn lines' from what I've seen.

Though, the actual 'slot' usage (I think mainly for 8x8 or 16x16 sprites) are preset in the first event of any actual sprite object. The byte itself can be modified in RAM since it's always stored into the object/enemy/projectile's RAM location for easy testing.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on December 10, 2017, 02:32:34 pm
The next update will be released before the end of the year, but it's not going to be a public release. Only paid subscribers will be able to test out the new features in-game. So I'm going to try and work with Luciano C. to get some donations.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on December 11, 2017, 11:46:10 am
I hope you're joking. No one should charge a dime for an editor of a game you didn't even make. The features you added so far aren't even stable. And I'm the one who's used the editor the most (in fact, me and the MMX: Generation dev are the only two people I know who use MegaEd X). So I don't see that working out well for you.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on December 15, 2017, 10:02:13 pm
Hart-Hunt,
I flagged your latest video on YouTube because it wasn't HD, and kept skipping. Listen, if editors want these updates then there's no reason why they can't make small donations to the staff (i.e. me,myself, and I). I'd be a lot more likely to program these changes to completion with an extra $20-50 per project (for 50 hours, which is less than the minimum wage btw). I already have bills paid, but there's no reason why I shouldn't expect payment for programming. The world isn't free, nor is entertainment and dining, or whatever I'd like to spend the money on (it's nobodies business).

In regards to Luciano. I tweeted him. He is busy with other projects and lost interest entirely in this program.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on December 16, 2017, 03:49:38 am
It doesn't make sense to expect money out of people either when there's people on here trying to help you understand the data beneath the game. It's like a slap to the face. We help you but you expect payment.

Yes, the world isn't free but this is not your program by source and it's been modified already by someone other than yourself and Xeeynamo.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Midna on December 16, 2017, 07:30:40 am
What possessed you to think locking a reverse-engineered fan-made modding tool for a game you don't own behind a paywall was a good idea? It's not. Capcom has every right to sue you into next decade for this.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on December 16, 2017, 10:57:46 am
Listen, if editors want these updates then there's no reason why they can't make small donations to the staff (i.e. me,myself, and I). I'd be a lot more likely to program these changes to completion with an extra $20-50 per project (for 50 hours, which is less than the minimum wage btw). I already have bills paid, but there's no reason why I shouldn't expect payment for programming. The world isn't free, nor is entertainment and dining, or whatever I'd like to spend the money on (it's nobodies business).

You should really think about what your doing by charging people for this. I highly doubt you get any more help from the rom hacking community. It's one thing if you did everything on your own and you want to charge people. How do you think all of the people that helped with this project feel about you charging people. You should be ashamed. You would get a lot more support if you set up some type of option for people to donate to you instead of forcing people to pay to test out new features in-game.

I really hope nobody pays for this. Just use the free version.
I'm almost out of this hole that I have been for the past 6-7 years and I will finally have the time to put my mmx editor together. It will be free of charge, open source, have a lot more features, and a lot less bugs.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on December 17, 2017, 03:04:41 pm
Capcom has every right to sue you into next decade for this.

I wouldn't be charging to use the program. It would still be open-source. I would be charging for my time as a programmer, either hourly, or as agreed in a negotiation, as an independent contractor. For payments under $2,000 it's not even required to be reported to the government on a 1099 form.

I would also not be asking for other's help on this website. I could look towards many of the resources online to find answers, or if I'm stumped, I could subcontract one, or more, to work on bugs, since some programmers here are practically magicians I can't explain it.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on December 17, 2017, 03:47:21 pm
Why don't you just give people the option to donate if they want to? Your actions are making you loose a lot of friends and the respect of others. Most people are on this site as a hobby not to make money. Pay it forward don't pay it backwards. I myself would not have the programming skills that I have if it wasn't for other people that helped me on this site and I'm very great full for it so I try to help whenever I can.
Yea programming and debugging is a ridiculous amount of work and it would be nice to get paid for it. But I don't think this is the right place for you to try and make money off of programming. You have every right to do as you please but I'm definitely not happy about it. If I were you I would just let people donate if they want to. Anyways that's my 2 cents do what ever you want.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on December 17, 2017, 03:58:24 pm
I'd say put up a donation only after it's gaining some traction at this point. With how many hours of work a lot of us have put to help the original, the second editor and yourself, it's definitely the better option out of any if you're going the pay route.

Either way, I'm stilling to welp whomever with MMX stuff as I want any editor to continue.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on December 17, 2017, 04:17:31 pm
You would still help even if people are forced to pay for updates?
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on December 17, 2017, 04:38:02 pm
If forced to pay, no. If donation wise without having to be forced, yes.

I'm willing to help most anyone who's willing to make an editor but if it's force pay then no.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on December 17, 2017, 04:57:08 pm
I feel the same way.

I don't think there is anything wrong with donations. But forcing people to pay just rubs me the wrong way. This editor still has a long way to go and it needs all the help it can get. I really hope money doesn't mess up this project.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: andrewclunn on December 17, 2017, 06:03:40 pm
If I can make a donation to ensure a particular feature comes next I'm fine with that.  So long as the project itself is open source then if somebody else wants to do the work they can.  Not paying for what you have done, but rather for what you will do
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on December 17, 2017, 06:16:35 pm
Im curious. What particular feature are you looking for?
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Midna on December 17, 2017, 07:12:05 pm
I feel the same way.

I don't think there is anything wrong with donations. But forcing people to pay just rubs me the wrong way. This editor still has a long way to go and it needs all the help it can get. I really hope money doesn't mess up this project.

Exactly. Most people into the ROM hacking scene are doing it out of passion or to better their own skills (Wave on this very site is a great example), not to turn a profit--and given that nobody here owns Mega Man X, the legality is very much up for debate. I feel like there are some things that shouldn't be turned into capitalist ventures, and this is one of them.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on December 17, 2017, 07:30:52 pm
I'm sure it's legal and he does have every right to ask for money if that's what he wants to do. I just don't think it's ethical because the creators can't create it on there own and they didn't create it on there own.

Image how much time these so called magicians spent debugging to find all of this magical rom data. I'm sure we put more time in debugging and finding rom data than it took to write the program and what do we ask for. We ask for nothing in return. We pride ourselves in helping others and we take pride in our hobbie. We put in a lot of work that people don't see and don't think about. Hard work and dedication and anybody can easily hack a rom or write a program. It's not magic it's dedication for what we love to do.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on December 17, 2017, 08:36:12 pm
Not counting the fact that he acted in completely bad faith, caring to look for my YT channel to flag my videos (which I never shared in a thread in RHDN)? No, I think that the attitude speaks for itself. He's made changes that haven't helped the development of the MMX romhacking scene, and then implied he shpuld expect payment for it.

I am one that makes his projects with a sense of community and will quickly turn my head around when I see someone like this guy trying to grt money out of someone else's work. Again, let's not forget the facts: he's going to make small changes to an editor that is functional as is, and then attempt to squeeze money out of the people who want to use it. Add that to the fact that he's asked the same people help for the development of said editor (I have PMs sent from him to me asking help on how it works), and then yeah, it's all too messed up to me, and I'd recommend everyone to see what I'm seeing and call him out on this.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: andrewclunn on December 17, 2017, 08:49:11 pm
Is he not making everything he's already done available for free?  Will future iterations not also be made available for free?  If you want to take up the project, is the code not available?  He's saying, "I have a life.  A little money will motivate me to prioritize this project.". That some people go into an anti-capitalist rant because somebody has the guts to ask for donations... I mean seriously, take your feigned outrage and shove it.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on December 17, 2017, 08:54:48 pm
He wasn't asking for donations is the problem. He was going to limit the use of his slightly modified versions of the editor to be SPECIFICALLY for people who pay.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: andrewclunn on December 17, 2017, 08:59:45 pm
He wasn't asking for donations is the problem. He was going to limit the use of his slightly modified versions of the editor to be SPECIFICALLY for people who pay.

Wait, what?  Okay, Maybe I misread a previous post.  If so my apologies to all.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on December 17, 2017, 09:09:11 pm
If he did what you implied, that'd be totally fine at least to me. That is, before the money-hungry attitude he has had already, which is simply toxic. That ship has sailed in my eyes.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on December 19, 2017, 05:50:51 am
Alright, you all don't get into too angry at me please. After all, up until now all of my changes have been free (and fixing the Overdrive Ostrich stage is still probably the biggest change). I know most up to 99% of the changes and hacks on this site are done without money being exchanged, and probably some of you are thinking I'm hijacking this program that wasn't even originally written by me. Unfortunately, the job market out here is pretty lackluster, and spending 2-3 hours programming on this when the only jobs in the area are forklift, or warehouse positions for min. wage is pretty demotivating. I'd rather be doing something like this, unfortunately it is iffy with the copyright and all. I was thinking Patreon, Kickstarter, or GoFundMe but I don't think I'd get enough traction to reach any goals.

I'd like to stay a member of this community for awhile, so don't be too bitter at me for wanting to make money for doing a hobby that I enjoy. I think everyone dreams to do what they love and make a career out of it. I will just look for a regular job in the area and make that a priority and do this in free time and spare hours, as usual. I appreciate all the feedback and help and input everyone has given, and I gave credit to many people in the github and Readme. Perhaps it is asking too much, even $5 for a cup of coffee, for donations. I don't know everyone's income and if a certain amount of money is too much for someone and I can't meet their deadlines I may just end up getting hate-mail and death threats.

I'm going to continue studying VRAM. There must be some place in memory, either RAM or ROM, where the size of enemy VRAM is stored. Once that hex value is found I can plug in equations in C++ and get those buttons to work. I'm guessing by the end of January that update will be done. Thanks for your input and I hope that we can all enjoy MegaEd X together.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on December 19, 2017, 07:37:11 am
Trust me no one thinks you are hijacking this program.
Xeeynamo released the source so others can work on it.
As far as I know everybody is happy that you are picking up where he left off. I'm sure every rom hacker on here would love to make money off of their hard work. It's just not gonna happen on here. You would get some money through donations if you had something set up for that but forcing people to pay for updates people will probably just stop using the editor. Your best chance at making money off of programming is by improving your skills and try to get on with some company. That's what I plan on doing.

The size of enemy vram is in the rom. More than one person has all of that stuff documented already. That's like really basic stuff to find. My test editor loads all vram correctly it's just written in QT and it won't be ready for awhile because I haven't been working on it. Most of my free time has been going to improving my skills.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on December 19, 2017, 10:07:35 am
Agreed wholeheartedly with john. No hard feelings. Xeeynamo's own actions, releasing the source code speak for themselves on the spirit of the romhacking community, made not for noney, but to see these great games shine. If people somehow decide to donate, that's their own decision and it should never be a forced one, but a donation. Especially because we don't own the games. If you want to make money out of a game, it should only be one that you've designed and programmed from scratch, with an engine you (or your team) made. That's how the world works.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on December 19, 2017, 04:19:48 pm
Hart-Hunt:
I do think anyone that creates a level editor for a game has every write to charge if they want to. I don't think anyone needs to create a game from scratch. Nobody is gonna get sued for making a editor for a game unless it has copyright material in it. Remember Nintendo tried suing the people that made the game genie and they lost. I think the legality of the game should be left out.

To all:
I just don't think this editor would even exist without romhacking.net. That's the reason I think the force of pay would be wrong. romhacking.net is a great community where people share, give, and teach. romhacking.net wouldn't be what it is if people were forcing payments for everything. Imagine if someone needed help with something and I said I'll help you if you pay me. If that happened we would no longer have romhacking.net and we won't have any new so called programming magicians. I won't have any programming skills if it wasn't for romhacking.net and I'm very great full to everyone that has helped me. There's really nothing left for me to say about all of this. I'm done.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on December 19, 2017, 06:50:30 pm
Hart-Hunt:
I do think anyone that creates a level editor for a game has every write to charge if they want to. I don't think anyone needs to create a game from scratch. Nobody is gonna get sued for making a editor for a game unless it has copyright material in it. Remember Nintendo tried suing the people that made the game genie and they lost. I think the legality of the game should be left out.
Oh, I'm not saying that based on legality, I'm talking about what makes the romhacking community a good one. See what I posted above:
I am one that makes his projects with a sense of community and will quickly turn my head around when I see someone like this guy trying to get money out of someone else's work.
It's not about the legality of it, it's about how the romhacking community is based on fans making games better, or different, for themselves, and for other fans. Because we're a community. And programming is as much of a job as game designing. And how many game designers are there in the romhacking community (not just RHDN) that do not even think of charging for their work? Because they are part of this community, which is not based on earning money. So yeah, I still maintain my point.

To all:
I just don't think this editor would even exist without romhacking.net. That's the reason I think the force of pay would be wrong. romhacking.net is a great community where people share, give, and teach. romhacking.net wouldn't be what it is if people were forcing payments for everything. Imagine if someone needed help with something and I said I'll help you if you pay me. If that happened we would no longer have romhacking.net and we won't have any new so called programming magicians. I won't have any programming skills if it wasn't for romhacking.net and I'm very great full to everyone that has helped me. There's really nothing left for me to say about all of this. I'm done.
I agree wholeheartedly, and it's based on that sentiment that I say that I said above in this very post.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on December 28, 2017, 03:36:14 am
I wasn't gonna post anything else on this page again but since I just now got a pm....

pianohombre:
Why are you sending me a pm for help? Are you scared to ask on here so everyone doesn't see it? How about you post exactly what you pm'd me on here! I'm more than willing to help out anybody but you have turned your back on everyone. Why should I help you? Post exactly what you pm'd me and I'll post your proof that I have it! And don't pm me unless you fix what you messed up. If you fix this I'll respond to your pm's. I'm sure people are wondering what's going on. There are people that have been following this editor for years. Don't leave them hanging wondering what's gonna happen with the editor. And if it's pay to play I'm not helping cause I'm not charging anyone!  >:(

And pianohombre you want help imagine if I said pay me! :-X

Video for what you are looking for. It is password protected. Post the pm you sent me and I'll post the password.
https://www.mediafire.com/file/ce9zzp881dtcgb4/mmx_sprite_vram_video.rar (https://www.mediafire.com/file/ce9zzp881dtcgb4/mmx_sprite_vram_video.rar)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on December 28, 2017, 09:19:19 am
I already said that I wasn't going to charge for updates, but might ask for donations and post a link. I don't know why you're trying to expose me, or something, but I'm not interested in playing any games. Now, that the holiday was over I was planning on continuing more work on the editor, and have already made one small change.

"And don't pm me unless you fix what you messed up"
I don't know what you're talking about? Do you mean how the dialog boxes don't attach to the parent window? You'll have to refresh my memory.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on December 28, 2017, 12:06:58 pm
You exposed yourself and I'm not playing games. This is my last post on this page. Don't pm me again for help!
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: NiO on December 28, 2017, 12:10:51 pm
Well, this is one of the few threads I take a look every now and then, after the "pay me to use the editor" message appeared I lost interest in it, mostly because I'm not really a guy that knows how to hack, and even less a guy that can pay for something like that.

TO be honest, it was a dick move, I got into something similar before and believe me, nothing good happens, I was helping to create the new Protoman 21XX game, I did sprites edits and even a few edits using the editor, but as soon as money began to be more important than the passion on it, it started to fall, little things made me go away from that project, some personal stuff but mostly and most important the one about the money... you want to play the game? you have to pay...

I have seen you decided to go the donation route, that's a better option, in that way, people like me that can use the editor, learn and do something nice out of it can go and in a way ($) say "thank you" instead of trying to go and download the editor and get a "F-U" while trying because we don't pay for it, because it feels that way, like a big FU on our faces.

Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on December 29, 2017, 02:56:53 pm
MegaEd X 1.4, everyone's greatest fears realized:

(http://img4.imagetitan.com/img4/small/17/17_megaedx_v14.jpg) (http://img4.imagetitan.com/img.php?image=17_megaedx_v14.jpg)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on December 29, 2017, 06:08:24 pm
Lmfao. Btw, something In noticed, in 1.3 the graphics in X1 don't get decompressed correctly. So you'll have to write exceptions for X1 or something.
Really Redguy has told me in the past that the editor, while it achieve significant breakthroughs in X1 modding, it needs a complete rewrite. And I'm inclined to agree; the GUI is a mess as is.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on December 30, 2017, 01:53:56 am
You mean there's an issue in 1.3 where graphics don't decompress properly, but they work fine in previous builds (ie Redguyyy's version)? Can you post an image showing an example?
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: Hart-Hunt on December 31, 2017, 02:19:50 pm
Left window is from RedGuy's version, right window is your latest build.
https://imgur.com/XFg1zBx
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on January 18, 2018, 02:33:16 pm
I've figured out the proper way to calculate the size of OAM by using no$sns, instead of bsnes. There you can determine the number of tiles, and their sizes by iterating through the graphics. However, I think it may just be unknown sizes and values of the sprites that are being rendered on-screen. Of course, what's-his-name claims to know the address locations of OAM sizes, that are in-game, yet he is being difficult. Fortunately, Hart-Hunt has created a list of sizes for MMX1, so worst-case scenario I could create a data structure that stores these values, but that means I would have to also find these values for X2-X3.

As far as special item sprites, such as the subtank and armor module, reading through more and more SNES documentation, I'm getting closer to discovering how the sprite is assembled by the emulator, yet it may take another six months to get this coded efficiently in the editor. There are a few sprites that aren't rendered properly in the editor, those 2 sets of sprites not being the only one. (The capsule for getting armor upgrades doesn't display properly in some levels, also RT-55J, and a couple other bosses/sub-bosses do not render correctly). The SNES complicated way of sending tile information to the write buffer along with options such as Vblank, makes it complicated to determine why and how some sprites aren't properly assembled.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: ThegreatBen on January 29, 2018, 09:01:57 am
Just curious, does this tool offer the ability to add new dialog boxes? So that all the added story from the psp version could be added to the snes.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on January 29, 2018, 12:25:06 pm
It does not. That requires either hefty event editing or massive dialogue. Either way you're going to need some ASM work done. Event wise, that'll be a large undertaking.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: ThegreatBen on January 29, 2018, 02:13:15 pm
Ya im definitely not going to do that, but thanks for the answer
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on February 08, 2018, 05:18:48 am
It does not. That requires either hefty event editing or massive dialogue. Either way you're going to need some ASM work done. Event wise, that'll be a large undertaking.

Really? I haven't edited large blocks of text in the game, but it's all there in plain-text viewable in a hex editor. I assumed you could just change the text and voila. It worked that way for a menu option, although I had to change the text in 3 different locations.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: justin3009 on February 08, 2018, 10:33:31 am
You can alter the text but to add in new dialogue that goes beyond requires some pointer relocating. Thankfully, Atlas and Cartographer do the job very well.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: renicito on February 12, 2018, 12:59:30 am
Hello friends, I'm new to this but I'm on the right track, I've made some progress in the translation of snes games, especially MegaMan X, I'm a loyal fan ... Maybe someone has the password to unzip this * .rar file " https://www.mediafire.com/file/ce9zzp881dtcgb4/mmx_sprite_vram_video.rar ", I publish Mr." slidelljohn ", when I had a discussion with" pianohombre ", I regret what happened to them but good a friendly hug friends ... Excuse my english I'm from Peru and I speak Spanish ... sometimes I use the google translator ... I apologize for them friends ...

A cordial greeting to "justin3009", it helped me a lot and I've learned many things since then when translating megaman x into Spanish ... thank you very much ...

Again I apologize for my audacity, I honestly want to continue learning ...  ;)
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: pianohombre on February 12, 2018, 11:29:28 pm
renicito,
You'll have to ask slidelljohn, for the password to that RAR file. He was pretty helpful in trying to understand how VRAM, DMA, and stuff works, but unfortunately I couldn't fix the C++ to make it assemble the tiles correctly how an emulator would do it. (The graphic is loaded in 2 separate routines, and I manually arranged the tiles through tedious work). I'm not sure how many graphics are loaded this way, but it looks like maybe Flammingle also may render this way. slidelljohn was pretty upset when I said that I was going to ask for donations for updates to the program (a statement I later retracted), since it was taking up a lot of time and I spent many nights up until 6AM coding.

Unfortunately, I'm not a computer and the code gets pretty complicated. I have tried trial&error method, trying to mimic what the hex is doing by shifting bytes and address locations, but so far it hasn't worked. His suggestion that the second part is at 0xCA00, rather than 0xC800, means I need to do something for those last two tiles. bitwise-shift? increment the address variable by 0x200? I think understanding how this DMA/OAM stuff works would be a huge leap in programming this game. Even Redguyyy suggested inner-core needs to be re-written. Problems like this is what he was talking about. Also, for most objects like energy tanks, 1-up, etc. everything needs to be set manually (palette info, assembly info ,etc.), rather than read automatically from the HEX.
Title: Re: MegaED X, the Megaman X hacking tool (Now with MMX2 support)
Post by: slidelljohn on February 13, 2018, 11:01:34 pm
Hello friends, I'm new to this but I'm on the right track, I've made some progress in the translation of snes games, especially MegaMan X, I'm a loyal fan ... Maybe someone has the password to unzip this * .rar file " https://www.mediafire.com/file/ce9zzp881dtcgb4/mmx_sprite_vram_video.rar ", I publish Mr." slidelljohn ", when I had a discussion with" pianohombre ", I regret what happened to them but good a friendly hug friends ... Excuse my english I'm from Peru and I speak Spanish ... sometimes I use the google translator ... I apologize for them friends ...

A cordial greeting to "justin3009", it helped me a lot and I've learned many things since then when translating megaman x into Spanish ... thank you very much ...

Again I apologize for my audacity, I honestly want to continue learning ...  ;)
The password is:
romhacking.net