HUD in S1 special stage

Discussion in 'Discussion and Q&A Archive' started by Professor Neo, Nov 21, 2008.

Thread Status:
Not open for further replies.
  1. Professor Neo

    Professor Neo Well-Known Member Member

    Joined:
    Nov 16, 2008
    Messages:
    103
    Location:
    United States
    Firstly, I have to remove the bubbles. Here are the two codes to remove the bubbles.


    Code 1


    PalCycle_SS:


    tst.w ($FFFFF63A).w


    bne.w locret_49E6


    subq.w #1,($FFFFF79C).w


    bpl.w locret_49E6


    lea ($C00004).l,a6


    move.w ($FFFFF79A).w,d0


    cmpi.w #$C,($FFFFF79A).w


    beq.b PalCycle_SS_NoIncrement


    addq.w #1,($FFFFF79A).w


    PalCycle_SS_NoIncrement:


    lsl.w #2,d0


    lea (byte_4A3C).l,a0


    andi.w #$3F,d0


    adda.w d0,a0


    move.b (a0)+,d0


    bpl.s loc_4992


    move.w #$1FF,d0


    Code 2


    byte_4A3C: dc.b 3, 0, 7, $92, 3, 0, 7, $90, 3, 0, 7, $8E, 3, 0, 7, $8C


    dc.b 3, 0, 7, $8B, 3, 0, 7, $80, 3, 0, 7, $82, 3, 0, 7, $84


    dc.b 3, 0, 7, $86, 3, 0, 7, $88, 7, 8, 7, 0, 7, $A, 7, $C


    dc.b $FF, $C, 7, $18, $FF, $C, 7, $18, 7, $A, 7, $C, 7, 8, 7, 0


    even


    byte_4ABC: dc.b $10, 1, $18, 0, $18, 1, $20, 0, $20, 1, $28, 0, $28, 1


    even


    I put these codes in the Special Stage subroutine:


    jsr HudUpdate


    jsr Hud_Base


    move.b #$21,($FFFFD040).w ; load HUD object


    The graphics were glitchy. But when I remove this:


    bsr.w ShowVDPGraphics


    That is the result you see. The HUD works perfectly but the scrolling clouds are gone as shown in the screenshot. The screenshot is small, but you should clearly see the HUD and the cloud-less background.

    /monthly_11_2008/post-584-1227295928_thumb.png
     

    Attached Files:

    Last edited by a moderator: Nov 21, 2008
  2. Spanner

    Spanner The Tool Member

    Joined:
    Aug 9, 2007
    Messages:
    2,570
    You know, you should credit Hayate for making the bubble removing guide.


    Just saying that by the way.
     
  3. Professor Neo

    Professor Neo Well-Known Member Member

    Joined:
    Nov 16, 2008
    Messages:
    103
    Location:
    United States
    Oh yeah. I forgot. Credits to Hayate for the bubble removal guide.


    I played Sonic: The Other Extended Edition and I saw the HUD working in the special stage. I wanted to do that for my hack.


    Now, here's a real problem: The clouds are there, but the HUD art doesn't load properly. The "E", colon, and "0" are uncompressed. So they load correctly.

    /monthly_11_2008/post-584-1227338083_thumb.gif
     

    Attached Files:

    Last edited by a moderator: Nov 22, 2008
  4. Spanner

    Spanner The Tool Member

    Joined:
    Aug 9, 2007
    Messages:
    2,570
    Use a different VRAM address for the Nemesis-compressed parts of the HUD. The current one is probably being overwritten by the Special Stage graphics.
     
  5. Professor Neo

    Professor Neo Well-Known Member Member

    Joined:
    Nov 16, 2008
    Messages:
    103
    Location:
    United States
    I figured it out!


    This is what I inserted:


    bsr.w LoadPLC2 ; load HUD art mappings


    I put it in the SS_BGLoad subroutine and I got this result:

    /monthly_11_2008/post-584-1227458484_thumb.gif
     

    Attached Files:

  6. Spanner

    Spanner The Tool Member

    Joined:
    Aug 9, 2007
    Messages:
    2,570
    Progress is good, but have you added a mention to HudUpdate? Other than that I don't know why the time isn't updating.
     
  7. Professor Neo

    Professor Neo Well-Known Member Member

    Joined:
    Nov 16, 2008
    Messages:
    103
    Location:
    United States
    The HUD update is located in the Main SS Loop. But I don't need the time limit. Here, I will show you a couple of things. If you look at the pictures, I am attempting to get the rings counter to flash as if it does in normal levels. If you look at the other picture, that there is my main goal: to edit the HUD mappings and get rid of the score and time counters and leave only the rings and lives counters. Also I want the rings counter in the exact positiion of the score counter. You may want to look at the pictures right to left to get what I'm talking about. And that first picture is a hoax--I edited the original screenshot in Paint. The HUD was originally not present at all; I drew the HUD into the screenshot.

    /monthly_11_2008/post-584-1227479478_thumb.gif

    /monthly_11_2008/post-584-1227479518_thumb.gif
     

    Attached Files:

    Last edited by a moderator: Nov 23, 2008
Thread Status:
Not open for further replies.