don't click here

Sonic 1: Enigma Credits

Discussion in 'Engineering & Reverse Engineering' started by Shadow Fire, Aug 31, 2015.

  1. Shadow Fire

    Shadow Fire

    Ultimate victory! Member
    1,557
    0
    16
    The Land of Darkness
    Sonic: The Lost Land (Series), The GCN (site)
    So, I got back into working on my Sonic hack, and came across the guide on the Retro wiki pertaining to Enigma Credits. However, I've noticed that the files that were provided both had broken links. Seriously, Easy Share? lol

    Anyway, I was wondering if anybody had the files that were there before the links died?
     
  2. Shadow Fire

    Shadow Fire

    Ultimate victory! Member
    1,557
    0
    16
    The Land of Darkness
    Sonic: The Lost Land (Series), The GCN (site)
    Thanks to someone (who oddly doesn't have a Retro account), I was able to come across the files. I've begun using them, but I've come across a little bug. The first two screens show perfectly fine, but the 3rd and 4th screens show this:

    [​IMG]

    [​IMG]

    Only the left side of the X and the bottom of the Y are showing, despite them both being there in the art/mappings file, as shown in PlaneED.

    [​IMG]

    [​IMG]
     
  3. Clownacy

    Clownacy

    Tech Member
    1,061
    607
    93
    So... any chance of a link, or did you already upload it to the wiki?
     
  4. Shadow Fire

    Shadow Fire

    Ultimate victory! Member
    1,557
    0
    16
    The Land of Darkness
    Sonic: The Lost Land (Series), The GCN (site)
    I knew there was something I was forgetting. I'll get it uploaded.

    Uploaded. :3
     
  5. Clownacy

    Clownacy

    Tech Member
    1,061
    607
    93
    Eww

    Code (ASM):
    1.         cmpi.w  #0,($FFFFFFF4).w ; is credit id = 0?
    2.         bne.s   EniCred1     ; if not, branch
    3.         lea (EniCred_0).l,a0 ; load credits enigma mappings
    4. EniCred1:
    5.         cmpi.w  #1,($FFFFFFF4).w ; is credit id = 1?
    6.         bne.s   EniCred2     ; if not, branch
    7.         lea (EniCred_1).l,a0 ; load credits enigma mappings
    8. EniCred2:
    This code's a bit of a mess. You can remove all that junk just by using an array. This seems to work well enough.

    About your bug, is there any chance those missing tiles are using the wrong palette line? PlaneEd and your hack seem to be using different palettes. S1's usually only has the one line, maybe yours spans all four.
     
  6. Shadow Fire

    Shadow Fire

    Ultimate victory! Member
    1,557
    0
    16
    The Land of Darkness
    Sonic: The Lost Land (Series), The GCN (site)
    I double checked, but they seem to be using the appropriate palette. As it happens, if I place the left side of the x on the right and flip it horizontally, it loads in the credits. Not sure why there's an issue with it.
     
  7. MarkeyJester

    MarkeyJester

    Original, No substitute Resident Jester
    2,202
    432
    63
    Japan
    I've noticed that both the X and the Y are missing, these letters happen to be right after byte C00 in you art list there. You have no other letter art showing on that screen that's after that point except the X and the Y, and those are the two that are screwing up. It would be a stretch, but I'd say that the art once loaded to VRAM, is being overwritten at it's C00 point (relative to wherever you loaded to art in VRAM), I'd suggest relocating the art in VRAM to another location, and seeing if that is indeed the reason.

    The only other reason I can think of, is the art isn't being saved correctly by PlaneEd, I'd doubt that mind, but you never know.

    EDIT: MainMemory ruins my fun again~
     
  8. MainMemory

    MainMemory

    Kate the Wolf Tech Member
    4,742
    338
    63
    SonLVL
    PlaneEd doesn't edit art, just mappings.
     
  9. Shadow Fire

    Shadow Fire

    Ultimate victory! Member
    1,557
    0
    16
    The Land of Darkness
    Sonic: The Lost Land (Series), The GCN (site)
    This is what I see during the credits when accessing the VDP feature.

    [​IMG]

    As you can see, some of the art after C00 is indeed missing, or messed up.

    UPDATE: I have an idea as to what's causing it. The level art loaded during the demo may be having an adverse effect on it, since when I check the VDP during the intro (SONIC TEAM PRESENTS), all the art is loaded correctly (although I haven't got the screen mapped out properly... still trying to figure out how to work that into the game similar to the EniCreds way). I was thinking of just removing the ending demo altogether, and just have credits playing.
     
  10. redhotsonic

    redhotsonic

    Also known as RHS Tech Member
    1,587
    10
    18
    United Kingdom
    YouTuber
    So it loads up fine but then something else over-writes it. So, after the 2nd screen, obviously something is being loaded that over-writes part of the HUD. Anything that you can find there that may be causing the issue? Try commenting it out if you do and jsut test to see if it helps. If it does, we have then found the issue.

    EDIT: Actually, I just noticed that it only seems to be X and Y that are screwed up (I should have read everyone's post before jumping in) and indeed it's from C000 causing the issue. So you just need to find out what's being loaded in at C000 and (re)move it (or as MJ said, move your art. You can move it from B400 to B200 and edit the mappings accordingly [unless you need to use them animals?].).
     
  11. Shadow Fire

    Shadow Fire

    Ultimate victory! Member
    1,557
    0
    16
    The Land of Darkness
    Sonic: The Lost Land (Series), The GCN (site)
    So, with help from redhotsonic, the credits now load fine. I simply moved their position in VRAM to where the animals would be loaded. I also had to make some minor adjustments to the PlaneED project files, which meant that I had to remap them, but that was a small price to pay.
     
  12. Clownacy

    Clownacy

    Tech Member
    1,061
    607
    93
    Oh. It might have been ClearScreen, which clears $C000 and $E000. They're usually used for defining which tiles are displayed on the FG/BG, not VRAM art.