Clownacy / ClownMapEd

Sonic the Hedgehog sprite editor, portable clone of Xenowhirl's SonMapEd.
GNU Affero General Public License v3.0
19 stars 1 forks source link

Can't load its own Pattern Load Cues (Sonic 1 format) #2

Closed SameytheHedgehog closed 1 year ago

SameytheHedgehog commented 1 year ago

When trying to re-open PLCs you've exported, CME says that they're "incompatible with the currently mappings" even if they're the exact same mappings you exported the PLCs with.

It can load any PLCs exported by SonMapEd however.

How to reproduce:

  1. Load mappings (e.g. Sonic's after being fixed so CME won't refuse to load it [just add Map_Sonic: to the beginning of the mappings])
  2. Load Sonic's PLCs
  3. Save the PLCs
  4. try loading the newly saved PLCs

I've also noticed that the PLCs that CME exports seem to be broken when loading them into SonMapEd, just making the mappings appear to be a garbled mess, especially for complex mappings that reference tiles all over the art file.

Default Sonic 1 (Old Hivebrain ASM68k) can't seem to load them properly either, as seemingly random frames will bug out and have the wrong tiles loaded.

SameytheHedgehog commented 1 year ago

Random side-note: CME can't seem to be able to load the original Sonic PLCs that come with the old Hivebrain asm68k disassembly, simply saying "file could not be assembled" when I try to load it.

Clownacy commented 1 year ago

Sonic's PLCs have the same issues as his mappings: they're missing the label at the start. Adding that gets the file to load successfully.

The reason that the exported PLCs cannot be loaded successfully is because you're trying to combine them with the original mappings: mappings and PLCs are 'paired' together, so trying to use mappings from one pair with PLCs from another pair will not work. You need to export both the mappings and the PLCs, and then you can load them.

Clownacy commented 1 year ago

With both the mappings and PLCs exported, the old Hivebrain disassembly seems to build and run fine. Since the game seems to handle it fine, I think SonMapEd displaying them wrong must be caused by a bug in SonMapEd, not ClownMapEd. Maybe I can rejig how PLCs are generated so that they're just as efficient as before, but will appear correctly in SonMapEd.

SameytheHedgehog commented 1 year ago

Ah I see now, I didn't think about the mappings and dplcs being paired up like this. After exporting both mappings and dplcs and building, it works perfectly fine. :)

SME would just let me load them in whichever way I wanted. That'll have to be something I just have to get used to I suppose.

I also suppose this one was just user-error for the most part so I'll just close this one as otherwise it'll mostly be a duplicate of the other issue.