Basic Questions and Answers Thread

Discussion in 'Discussion & Q&A' started by Malevolence, Jul 7, 2009.

  1. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
    I'm using the dynamic tileset tutorial to see if my problem was solved but it's the same...
    Is it impossible to edit a different palette for each act of the same zone in SonLVL?
     
  2. ProjectFM

    ProjectFM Optimistic and self-dependent Member

    Joined:
    Oct 4, 2014
    Messages:
    912
    Location:
    Orono, Maine
    I've tried adding Sonic 3's ring manager (provided by this tutorial) into Sonic 1 because S1's ring formations don't work right with Sonic 3's object manager which I also added. However, I experienced a problem I've never encountered before. What happens is that an error is caused when returning from the RingsManager_Setup subroutine and it seems like it happens between commands. And making it so the subroutine is part of the code that branches to it doesn't change anything.
    [​IMG]
    The left is when I added "illegal" to the end of RingsManager_Setup and the right is the error I'm getting. Also, I rearranged the RAM addresses to their positions in Sonic 2 to make space if that's any help.
     
  3. vladikcomper

    vladikcomper Well-Known Member Member

    Joined:
    Dec 2, 2009
    Messages:
    415
    ProjectFM, it appears something has messed up the RAM completely, more precisely, it looks like a broken memory clear loop, that clears not what it should, or much more than it should. As the result, even the stack gets cleared and all return addresses are erased.
    Which is why you're getting this error: since stack is totally zeroed, it returns to offset $000000 (startofrom) and the illegal instruction exception is triggered immediately as the processor's trying to execute data and not some proper code.

    What also gets my attention is the subroutine name on the intentional crash at the left screenshot, loc_172b1. Out of curiosity, why does it happen to name an odd address? Was it provided by some tutorial you've used or did you come up with this random name to avoid confusion with stock Sonic 1 routines?
     
    Last edited: May 29, 2016
    ProjectFM likes this.
  4. ProjectFM

    ProjectFM Optimistic and self-dependent Member

    Joined:
    Oct 4, 2014
    Messages:
    912
    Location:
    Orono, Maine
    Thanks! I'll go see what's causing that problem.

    I came up with label to replace the + used for the AS assembler. The each label was a number after the other, starting at loc_172AE.

    Edit: The cause was that I didn't change the ClearRAM macro into code correctly.
     
    Last edited: May 29, 2016
  5. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
  6. ProjectFM

    ProjectFM Optimistic and self-dependent Member

    Joined:
    Oct 4, 2014
    Messages:
    912
    Location:
    Orono, Maine
    The problem is the pattern load cues are being overwritten. You need to make sure no other art is using the same RAM as the bubbles and stuff.

    Now for my own:
    Here is the code for the ring manager I ported to Sonic 1. For some reason, no rings are created despite all the code being the same as in the guide I used. Here's the code:
    Code:
    RingsManager:
        moveq    #0,d0
        move.b    ($FFFFFE17).w,d0
        move.w    RingsManager_States(pc,d0.w),d0
        jmp    RingsManager_States(pc,d0.w)
    ; ===========================================================================
    ; off_16F96:
    RingsManager_States:
        dc.w RingsManager_Init-RingsManager_States
        dc.w RingsManager_Main-RingsManager_States
    ; ===========================================================================
    ; loc_16F9A:
    RingsManager_Init:
        addq.b    #2,($FFFFFE17).w ; => RingsManager_Main
        bsr.w    RingsManager_Setup
        movea.l    ($FFFFE800+Rings_Space).w,a1
        lea    ($FFFFE800).w,a2
        move.w    ($FFFFF700).w,d4
        subq.w    #8,d4
        bhi.s    loc_16FB6
        moveq    #1,d4
        bra.s    loc_16FB6
    ; ===========================================================================
    
    loc_16FB2:
        addq.w    #4,a1
        addq.w    #2,a2
    
    loc_16FB6:
        cmp.w    (a1),d4
        bhi.s    loc_16FB2
        move.l    a1,($FFFFE800+Rings_Space).w
        move.w    a2,($FFFFF7A2).w
        addi.w    #$150,d4
        bra.s    loc_16FCE
    ; ===========================================================================
    
    loc_16FCA:
        addq.w    #4,a1
    
    loc_16FCE:
        cmp.w    (a1),d4
        bhi.s    loc_16FCA
        move.l    a1,($FFFFE800+Rings_Space+4).w
        rts
    ; ===========================================================================
    ; loc_16FDE:
    RingsManager_Main:
        lea    ($FFFFEF80).w,a2
        move.w    (a2)+,d1
        subq.w    #1,d1
        bcs.s    loc_17014
    
    loc_16FE8:
        move.w    (a2)+,d0
        beq.s    loc_16FE8
        movea.w    d0,a1
        subq.b    #1,(a1)
        bne.s    loc_17010
        move.b    #6,(a1)
        addq.b    #1,1(a1)
        cmpi.b    #8,1(a1)
        bne.s    loc_17010
        move.w    #-1,(a1)
        move.w    #0,-2(a2)
        subq.w    #1,($FFFFEF80).w
    
    loc_17010:
        dbf    d1,loc_16FE8
    
    loc_17014:
        movea.l    ($FFFFE800+Rings_Space).w,a1
        movea.w    ($FFFFF7A2).w,a2
        move.w    ($FFFFF700).w,d4
        subq.w    #8,d4
        bhi.s    loc_17028
        moveq    #1,d4
        bra.s    loc_17028
    ; ===========================================================================
    
    loc_17024:
        addq.w    #4,a1
        addq.w    #2,a2
    
    loc_17028:
        cmp.w    (a1),d4
        bhi.s    loc_17024
        bra.s    loc_17032
    ; ===========================================================================
    
    loc_17030:
        subq.w    #4,a1
        subq.w    #2,a2
    
    loc_17032:
        cmp.w    -4(a1),d4
        bls.s    loc_17030
        move.l    a1,($FFFFE800+Rings_Space).w
        move.w    a2,($FFFFF7A2).w
        movea.l    ($FFFFE800+Rings_Space+4).w,a2
        addi.w    #$150,d4
        bra.s    loc_1704A
    ; ===========================================================================
    
    loc_17046:
        addq.w    #4,a2
    
    loc_1704A:
        cmp.w    (a2),d4
        bhi.s    loc_17046
        bra.s    loc_17054
    ; ===========================================================================
    
    loc_17052:
        subq.w    #4,a2
    
    loc_17054:
        cmp.w    -4(a2),d4
        bls.s    loc_17052
        move.l    a2,($FFFFE800+Rings_Space+4).w
        rts
    ; ===========================================================================
    
    loc_170BA:
        movea.l    ($FFFFE800+Rings_Space).w,a1
        movea.l    ($FFFFE800+Rings_Space+4).w,a2
    
    loc_170D0:
        cmpa.l    a1,a2
        beq.w    return_17166
        movea.w    ($FFFFF7A2).w,a4
        cmpi.w    #$5A,$30(a0)
        bcc.w    return_17166
        cmpi.b    #1,($FFFFFE2C).w    ; does Sonic have a lightning shield?
        beq.s    Touch_Rings_NoAttraction    ; if not, branch
        move.w    8(a0),d2
        move.w    $C(a0),d3
        subi.w    #$40,d2
        subi.w    #$40,d3
        move.w    #6,d1
        move.w    #$C,d6
        move.w    #$80,d4
        move.w    #$80,d5
        bra.s    loc_17112
    ; ===========================================================================
      
    Touch_Rings_NoAttraction:
        move.w    8(a0),d2
        move.w    $C(a0),d3
        subi.w    #8,d2
        moveq    #0,d5
        move.b    $16(a0),d5
        subq.b    #3,d5
        sub.w    d5,d3
        cmpi.b    #$4D,4(a0)
        bne.s    loc_17111
        addi.w    #$C,d3
        moveq    #$A,d5
    
    loc_17111:
        move.w    #6,d1
        move.w    #$C,d6
        move.w    #$10,d4
        add.w    d5,d5
    
    loc_17112:
        tst.w    (a4)
        bne.w    loc_1715C
        move.w    (a1),d0
        sub.w    d1,d0
        sub.w    d2,d0
        bcc.s    loc_1712A
        add.w    d6,d0
        bcs.s    loc_17130
        bra.w    loc_1715C
    ; ===========================================================================
    
    loc_1712A:
        cmp.w    d4,d0
        bhi.w    loc_1715C
    
    loc_17130:
        move.w    2(a1),d0
        sub.w    d1,d0
        sub.w    d3,d0
        bcc.s    loc_17142
        add.w    d6,d0
        bcs.s    loc_17148
        bra.w    loc_1715C
    ; ===========================================================================
    
    loc_17142:
        cmp.w    d5,d0
        bhi.w    loc_1715C
    
    loc_17148:
        btst    #5,$2B(a0)
        bne.s    AttractRing
      
    loc_17148_cont:
        move.w    #$604,(a4)
        bsr.s    loc_17168
        lea    ($FFFFEF82).w,a3
    
    loc_17152:
        tst.w    (a3)+
        bne.s    loc_17152
        move.w    a4,-(a3)
        addq.w    #1,($FFFFEF80).w
    
    loc_1715C:
        addq.w    #4,a1
        addq.w    #2,a4
        cmpa.l    a1,a2
        bne.w    loc_17112
    
    return_17166:
        rts
    ; ===========================================================================
    
    loc_17168:
        subq.w    #1,($FFFFF712).w
        bra.w    CollectRing
    ; ===========================================================================
    
    AttractRing:
        movea.l    a1,a3
        jsr    SingleObjLoad
        bne.w    AttractRing_NoFreeSlot
        move.b    #$4C,(a1)
        move.w    (a3),8(a1)
        move.w    2(a3),$C(a1)
    ;    move.w    a0,parent(a1)
        move.w    #-1,(a4)
        rts  
    ; ===========================================================================
      
    AttractRing_NoFreeSlot:
        movea.l    a3,a1
        bra.s    loc_17148_cont
    ; ===========================================================================
    
    loc_17178:
        movea.l    ($FFFFE800+Rings_Space).w,a0
        move.l    ($FFFFE800+Rings_Space+4).w,d7
        sub.l    a0,d7
        bne.s    loc_17186
        rts
    ; ===========================================================================
    
    loc_17186:
        movea.w    ($FFFFF7A2).w,a4
        lea    ($FFFFF700).w,a3
    
    loc_1718A:
        tst.w    (a4)+
        bmi.w    loc_171EC
        move.w    (a0),d3
        sub.w    (a3),d3
        addi.w    #$80,d3
        move.w    2(a0),d2
        sub.w    4(a3),d2
        andi.w    #$7FF,d2
        addi.w    #8,d2
        bmi.s    loc_171EC
        cmpi.w    #$F0,d2
        bge.s    loc_171EC
        addi.w    #$78,d2
        lea    (Map_Obj25).l,a1
        moveq    #0,d1
        move.b    -1(a4),d1
        bne.s    loc_171C8
        move.b    ($FFFFFEC3).w,d1
    
    loc_171C8:
        add.w    d1,d1
        adda.w    (a1,d1.w),a1
        move.b    (a1)+,d0
        ext.w    d0
        add.w    d2,d0
        move.w    d0,(a2)+
        move.b    (a1)+,(a2)+
        addq.b    #1,d5
        move.b    d5,(a2)+
        move.w    (a1)+,d0
        addi.w    #$247C,d0
        move.w    d0,(a2)+
        addq.w    #2,a1
        move.w    (a1)+,d0
        add.w    d3,d0
        move.w    d0,(a2)+
    
    loc_171EC:
        addq.w    #4,a0
        subq.w    #4,d7
        bne.w    loc_1718A
        rts
    ; ===========================================================================
    
    loc_171F8:
        lea    ($FFFFF700).w,a3
        move.w    #$78,d6
        movea.l    ($FFFFE800+Rings_Space).w,a0
        move.l    ($FFFFE800+Rings_Space+4).w,d7
        movea.w    ($FFFFF7A2).w,a4
        sub.l    a0,d7
        bne.s    loc_17224
        rts
    ; ===========================================================================
    
    loc_17224:
        tst.w    (a4)+
        bmi.w    loc_17288
        move.w    (a0),d3
        sub.w    (a3),d3
        addi.w    #$80,d3
        move.w    2(a0),d2
        sub.w    4(a3),d2
        andi.w    #$7FF,d2
        addi.w    #$88,d2
        bmi.s    loc_17288
        cmpi.w    #$170,d2
        bge.s    loc_17288
        add.w    d6,d2
        lea    (Map_Obj25).l,a1
        moveq    #0,d1
        move.b    -1(a4),d1
        bne.s    loc_17260
        move.b    ($FFFFFEC3).w,d1
    
    loc_17260:
        add.w    d1,d1
        adda.w    (a1,d1.w),a1
        move.b    (a1)+,d0
        ext.w    d0
        add.w    d2,d0
        move.w    d0,(a2)+
        move.b    (a1)+,d4
        move.b    byte_17294(pc,d4.w),(a2)+
        addq.b    #1,d5
        move.b    d5,(a2)+
        addq.w    #2,a1
        move.w    (a1)+,d0
        addi.w    #$235E,d0
        move.w    d0,(a2)+
        move.w    (a1)+,d0
        add.w    d3,d0
        move.w    d0,(a2)+
    
    loc_17288:
        addq.w    #4,a0
        subq.w    #4,d7
        bne.w    loc_17224
        rts
    ; ===========================================================================
    ; unknown
    byte_17294:
        dc.b   0,0    ; 1
        dc.b   1,1    ; 3
        dc.b   4,4    ; 5
        dc.b   5,5    ; 7
        dc.b   8,8    ; 9
        dc.b   9,9    ; 11
        dc.b  $C,$C    ; 13
        dc.b  $D,$D    ; 15
    ; ===========================================================================
    
    RingsManager_Setup:
        lea    ($FFFFE800).w,a1
        moveq    #0,d0
        move.w    #Rings_Space/4-1,d1
    
    loc_172AE:                ; CODE XREF: h+33Cj
        move.l    d0,(a1)+
        dbf    d1,loc_172AE
    
        lea    ($FFFFEF80).w,a1
        move.w    #$1F,d1
    
    loc_172AF:
        move.l    d0,(a1)+
        dbf    d1,loc_172AF
    
        moveq    #0,d5
        moveq    #0,d0
        move.w    ($FFFFFE10).w,d0
        lsl.b    #6,d0
        lsr.w    #4,d0
        lea    (RingPos_Index).l,a1
        move.w    (a1,d0.w),d0
        lea    (a1,d0.w),a1
        move.l    a1,($FFFFE800+Rings_Space).w
        addq.w    #4,a1
        moveq    #0,d5
        move.w    #(Max_Rings-1),d0
    
    loc_172B0:
        tst.l    (a1)+
        bmi.s    loc_172B1
        addq.w    #1,d5
        dbf    d0,loc_172B0
    
    loc_172B1:
        move.w    d5,($FFFFF712).w
        move.w    #0,($FFFFF716).w    ; no idea what this is
        rts
    Could anyone figure out the problem? I rearranged the RAM addresses to their positions in Sonic 2 to make space and $FFFFF7A2 is used for Ring_start_addr_RAM. Also, the code is loaded under Level_LoadObj and Level_MainLoop. Lastly, I made sure the addresses are correct when loading the ring positions.
     
  7. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
    And how can i know what is the good RAM adresse to use?
     
  8. Painto

    Painto Arthurus Paintus Erinaceus Member

    Joined:
    Mar 24, 2014
    Messages:
    321
    Location:
    Lublin, Poland
    Open the hack with Regen, load (completely) the level you want, open the VDP Debugger and search in the window on the left for empty and/or leftover tiles from previous levels/screens.
     
  9. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
    I'll probably look like a dick but what is "Regen"?
     
  10. Clownacy

    Clownacy Retired Staff lolololo Member

    Joined:
    Aug 15, 2014
    Messages:
    1,020
  11. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
    Sorry for the doube post, but now i have Regen and i'm in my level. But the VDP Debugger dont work...
     
  12. Clownacy

    Clownacy Retired Staff lolololo Member

    Joined:
    Aug 15, 2014
    Messages:
    1,020
    "Doesn't work" is the least helpful thing you could possibly say when describing an error. How do you expect it to work? How does it not perform to your expectations? For all I know, the VDP debug window option is greyed out, or the window just displays blank, or the VRAM contents is wrongly displaying empty.
     
    MarkeyJester likes this.
  13. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
    VDP Debug in "Tools" is Grey (sorry!)
     
  14. Clownacy

    Clownacy Retired Staff lolololo Member

    Joined:
    Aug 15, 2014
    Messages:
    1,020
    You're using the standard version of Regen; you need the debugging version, "Regen 0.972D".
     
  15. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
    Ok thank you i'll take it!

    Ok i have this http://image.noelshack.com/fichiers/2016/21/1464550528-sans-titre.png!
    I don't understand anything, i try to understand by myself but when i want to look at the offset tile list at left, the offset go until 0x05DC...

    EDIT: Sorry again for double posting, it's not my intention!
     
    Last edited: May 29, 2016
  16. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
    Sorry for double (triple) posting!

    EDIT: my problem is resolved
     
    Last edited: May 30, 2016
  17. vladikcomper

    vladikcomper Well-Known Member Member

    Joined:
    Dec 2, 2009
    Messages:
    415
    EDIT: It appears I'm late and Ashuro has sorted out this issue on his own.
    Since the issue above has been resolved already and contents of the above post have been removed, my reply doesn't make much sense now.
    But I'd still like to keep if for a while, albeit under the spoiler tag. Perhaps, Ashuro also will find the analysis of his code I provided helpful.

    Ashuro, Sonic always goes to the right, because your code always sets $14(a0) to $C00, regardless Sonic's direction. You are also doing some odd calculations based on the $14(a0) value in register D0, but you don't seem to use them anywhere, so they have no effect eventually.

    To make it even easier for you, let's see how the processor "sees" this code, and what you'll get once it's executed:
    Code:
    ; Let $14(a0) = X
    
    B_Direction:
            btst    #0,$22(a0)              ; test bit #0 of $22(a0)
            beq.s   B_Direction2            ; if bit is clear, branch
            neg.w   $14(a0)                 ; $14(a0) = -X
    
    B_Direction2:
            move.w  #1,$10(a0)              ; $10(a0) = 1
            move.w  #$0C00,$14(a0)          ; $14(a0) = $C00
            move.w  $14(a0),d0              ; d0 = $14(a0) = $C00 ...
            subi.w  #$800,d0                ;   ... + $800 = $400
            add.w   d0,d0                   ;   ... * 2 = $800
            andi.w  #$1F00,d0               ;   ... & $1F00 = $800
            addi.w  #$2000,d0               ;   ... + $2000 = $2800
    
    B_End:
            rts ; return
    
    ; By the end of code we get:
    ;       $14(a0) = $C00
    ;            d0 = $2800 (UNUSED!)
    
    
    $14(a0) is always $C00, because
    Code:
            move.w  #$0C00,$14(a0)          ; $14(a0) = $C00
    is executed anyways.

    To be more specific, you are checking, whether Sonic is facing right or not, here:
    Code:
            btst    #0,$22(a0)  
    1. If Sonic's facing right, then ...
      Code:
              beq.s  B_Direction2  
      ... jumps to the location pointed by B_Direction2 and the processor will execute the following instructions:
      Code:
              move.w  #1,$10(a0)              ; $10(a0) = 1
              move.w  #$0C00,$14(a0)          ; $14(a0) = $C00
              move.w  $14(a0),d0              ; d0 = $14(a0) = $C00 ...
              subi.w  #$800,d0                ;   ... + $800 = $400
              add.w   d0,d0                   ;   ... * 2 = $800
              andi.w  #$1F00,d0               ;   ... & $1F00 = $800
              addi.w  #$2000,d0               ;   ... + $2000 = $2800
              rts 
      
      In this case, $14(a0) is set to $C00.

    2. If Sonic's facing left, then ...
      Code:
              beq.s  B_Direction2  
      ... won't jump, the processor will execute the underlying instructions. So it will execute the following:
      Code:
              neg.w   $14(a0)                 ; $14(a0) = -X
              move.w  #1,$10(a0)              ; $10(a0) = 1
              move.w  #$0C00,$14(a0)          ; $14(a0) = $C00
              move.w  $14(a0),d0              ; d0 = $14(a0) = $C00 ...
              subi.w  #$800,d0                ;  ... + $800 = $400
              add.w  d0,d0                  ;  ... * 2 = $800
              andi.w  #$1F00,d0              ;  ... & $1F00 = $800
              addi.w  #$2000,d0              ;  ... + $2000 = $2800
              rts
      
      In this case, again, $14(a0) is set to $C00.
      So the extra NEG instruction you're doing in case Sonic's facing left has no effect, as the value gets overwritten anyways.
     
    Last edited: May 30, 2016
    FireRat likes this.
  18. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
    Thank for this lesson, i learn more about asm everydays :p

    I want to post it, i have resolved my problem like this:
    ;======================================================================================
    B_Direction:
    move.w #1,$10(a0) ; force X speed to nonzero for camera lag's benefit
    move.w #$0C00,$14(a0)
    move.w $14(a0),d0
    subi.w #$800,d0
    add.w d0,d0
    andi.w #$1F00,d0
    neg.w d0
    addi.w #$2000,d0
    ;move.w d0,(v_cameralag).w
    btst #0,$22(a0)
    beq.s B_Direction2
    neg.w $14(a0)

    B_Direction2:
    bclr #7,$22(a0)
    move.w #$BC,d0
    jsr (PlaySound_Special).l
    bra.w B_End
    ;======================================================================================
     
  19. vladikcomper

    vladikcomper Well-Known Member Member

    Joined:
    Dec 2, 2009
    Messages:
    415
    ProjectFM, are you sure not a single ring is loaded? Your the code seems okay at the first glace, I'm sure it does at least something right, provided you feed it with the correct data and it doesn't crash or cause major memory corruption.
    Another good question is... do you actually display the rings?

    In stock Sonic 1, creating an object and calling DisplaySprite inside it is pretty much the only way display a sprite. The object requested will be later processed by the BuildSprites routine, it's sprite mappings will be converted and sent to the VDP's sprite buffer.

    In Sonic 2, they expanded BuildSprites to handle more than just some plain objects. First off, they added child sprites system, so a single object can display and move multiple sprite frames at once (used for invincibility stars and starpost stars). Second off, they hardcoded HUD displaying into the BuildSprites itself (so HUD didn't have to occupy an object slot anymore, which saves some memory).
    And last but not least, they separated rings from the objects system, introducing the rings manager, which handled rings more effectively in terms of memory and processor resources (because wasting the entire object slot on a single ring isn't a good use for rather slow and complex objects system). Since rings manager doesn't use proper object slots to keep rings, they have to be displayed (converted to sprites) on their own.

    So, in Sonic 2 and Sonic 3, there's a part of rings manager that handles rings displaying. Check out BuildSprites in Sonic 2, it jumps to BuildRings right in the beginning, which, obviously, build all the rings sprites.
    So, I ask you again... do you actually display the rings?

    In the code you provided, there are actually subroutines that handle sprite displaying: loc_17178, loc_171F8 and loc_1720E. There are never referenced to in the code, which is correct. You should call them in BuildSprites.
    You have specified that you jump to the RingsManager subroutine somewhere, but do you actually call the ones I listed?
    These routine names come from Sonic 2, they are called BuildRings, BuildRings_P1 and BuildRings_P2 respectively in the newer disassemblies. So if you apply this guide in Sonic 2, there's no problem: you'll just overwrite the existing routines and they'll still be called from BuildSprites. But in Sonic 1, the won't.

    Make sure you call them where appropriate, make sure they are compatible with Sonic 1's BuildSprites.
     
    ProjectFM likes this.
  20. ProjectFM

    ProjectFM Optimistic and self-dependent Member

    Joined:
    Oct 4, 2014
    Messages:
    912
    Location:
    Orono, Maine
    That must be the problem. Thanks! I'll try adding that.

    Edit: I added the branch to loc_17178 along with the flag for if the level has started but now, the branch back to loc_1718A is causing an address error.

    Edot2: Nevermind. I made BuildSprites branch to the wrong place.
     
    Last edited: May 30, 2016