Dynamically Loading Ring Animation Frames into VRAM in Sonic 1

Discussion in 'Tutorials' started by Devon, Jul 18, 2023.

  1. Devon

    Devon I'm a loser, baby, so why don't you kill me? Member

    Joined:
    Aug 26, 2013
    Messages:
    1,376
    Location:
    your mom
    Can you show me a VRAM dump where the rings graphics are?
     
  2. ProjectFM

    ProjectFM Optimistic and self-dependent Member

    Joined:
    Oct 4, 2014
    Messages:
    912
    Location:
    Orono, Maine
    I noticed that the rings continue to animate when you die, which isn't supposed to happen in Sonic 1. I was able to solve this by inserting this after the LoadRingFrame label:
    Code:
            cmpi.b    #6,(v_player+obRoutine).w     ; has Sonic just died?
            bhs.s    .noringloss            ; if so, don't animate rings
    Otherwise, this is a fantastic tutorial.
     
    Dark Shamil Khan likes this.
  3. B.T.H Yeehaw!

    B.T.H Yeehaw! Newcomer Member

    Joined:
    Jun 20, 2020
    Messages:
    15
    Location:
    City Streets Zone
    I can, actually, and I'm very baffled by this. (Look down at the bottom.)
    What the hell is it doing.png
     
  4. Devon

    Devon I'm a loser, baby, so why don't you kill me? Member

    Joined:
    Aug 26, 2013
    Messages:
    1,376
    Location:
    your mom
    Turns out that they applied the tile ID change of 27B2 to 27B6 to the wrong object. It was meant for RingLoss, not Rings.

    The result of the error is that the regular rings are displaying the lost ring frame and the regular ring sparkles' tile ID gets shifted alongside that and ends up displaying crap from the sprite table, and the lost rings are displaying the regular ring frame.
     
    Last edited: Sep 21, 2023
  5. Thiago REzEnDe

    Thiago REzEnDe Newcomer Trialist

    Joined:
    Sep 17, 2022
    Messages:
    9
    Location:
    Hill Valey, California
    Heyo so, I'm having a similar problem as B.T.H was having, but instead, the rings look like this when i lose them..
     

    Attached Files:

  6. Devon

    Devon I'm a loser, baby, so why don't you kill me? Member

    Joined:
    Aug 26, 2013
    Messages:
    1,376
    Location:
    your mom
    Looks like it's reading invalid mappings data. Did you follow this step?
     
  7. Thiago REzEnDe

    Thiago REzEnDe Newcomer Trialist

    Joined:
    Sep 17, 2022
    Messages:
    9
    Location:
    Hill Valey, California
    yes i did remove the lines, i also forgot to tell l'm using hivebrain 2005
     
  8. Devon

    Devon I'm a loser, baby, so why don't you kill me? Member

    Joined:
    Aug 26, 2013
    Messages:
    1,376
    Location:
    your mom
    You didn't remove the second line.