Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ; ===========================================================================
- ; ---------------------------------------------------------------------------
- ; Object 21 - SCORE, TIME, RINGS
- ; ---------------------------------------------------------------------------
- Obj21: ; XREF: Obj_Index
- moveq #0,d0
- move.b $24(a0),d0
- move.w Obj21_Index(pc,d0.w),d1
- jmp Obj21_Index(pc,d1.w)
- ; ===========================================================================
- Obj21_Index: dc.w Obj21_Main-Obj21_Index
- dc.w Obj21_Show-Obj21_Index
- dc.w Obj21_Hide-Obj21_Index
- ; ===========================================================================
- Obj21_Main: ; XREF: Obj21_Main
- addq.b #2,$24(a0)
- move.w #0,8(a0) ; was $90
- move.w #$108,$A(a0)
- move.l #Map_obj21,4(a0)
- move.w #var_HUDVram/$20,2(a0)
- move.b #0,1(a0)
- move.b #0,$18(a0)
- ; ===========================================================================
- Obj21_Show:
- cmpi.w #$90,8(a0)
- bcc.s Obj21_Flash
- addq.w #4,8(a0)
- jmp DisplaySprite
- Obj21_Flash: ; XREF: Obj21_Main
- clr.b $1A(a0) ; make all counters yellow
- tst.w ($FFFFFE20).w ; do you have any rings?
- beq.s @RingFlash ; if not, branch
- jmp DisplaySprite
- @RingFlash btst #3,($FFFFFE05).w
- bne.s @Display
- move.b #1,$1A(a0)
- @Display jmp DisplaySprite
- ; ===========================================================================
- Obj21_Hide:
- tst.w 8(a0) ; has the HUD reached $0 by X-pos?
- beq @Delete ; if yes, branch
- subi.w #2,8(a0)
- jmp DisplaySprite
- @Delete jmp DeleteObject
- ; ===========================================================================
- ; ---------------------------------------------------------------------------
- ; Sprite mappings - SCORE, TIME, RINGS
- ; ---------------------------------------------------------------------------
- Map_obj21:
- dc.w @HUD_Normal-Map_obj21
- dc.w @HUD_RingFlash-Map_obj21
- @HUD_Normal dc.b 4
- dc.b $80, $F, $80, 0, 0 ; SCORE & TIME counters
- dc.b $80, $F, $80, $10, $20 ; SCORE & TIME counters
- dc.b $9F, 5, $A0, $FC-2, 0 ; Ring Icon
- dc.b $A0, 9, $80, $20, $10 ; RING Counter
- @HUD_RingFlash dc.b 4
- dc.b $80, $F, $80, 0, 0 ; SCORE & TIME counters
- dc.b $80, $F, $80, $10, $20 ; SCORE & TIME counters
- dc.b $9F, 5, $80, $FC-2, 0 ; ring
- dc.b $A0, 9, $80, $20, $10 ; RING Counter
- even
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement