Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ; ---------------------------------------------------------------------------
- ; Босс-смертельный шар
- ; ---------------------------------------------------------------------------
- ; Hits
- BossRobot_Hits = 12
- ; Attributes
- _Setup1 = 2
- _Setup2 = 4
- _Setup3 = 6
- ; Animates
- setOpen = 1
- setClose = 2
- ; =============== S U B R O U T I N E =======================================
- Obj_BossRobot:
- moveq #0,d0
- move.b obRoutine(a0),d0
- move.w BossRobot_Index(pc,d0.w),d0
- jsr BossRobot_Index(pc,d0.w)
- bsr.w BossRobot_CheckTouch
- lea Ani_BossRobot(pc),a1
- jsr (Animate_Sprite).l
- jmp (Draw_And_Touch_Sprite).l
- ; ---------------------------------------------------------------------------
- BossRobot_Index: offsetTable
- offsetTableEntry.w BossRobot_Init ; 0
- offsetTableEntry.w BossRobot_Setup ; 2
- offsetTableEntry.w BossRobot_Setup2 ; 4
- ; ---------------------------------------------------------------------------
- BossRobot_Init:
- lea ObjDat3_BossRobot(pc),a1
- jsr (SetUp_ObjAttributes).l
- move.b #-1,$29(a0)
- move.b #1,(Boss_flag).w
- move.b #36,y_radius(a0)
- move.l #BossRobot_Robotnik_Intro,$34(a0)
- jmp (Swing_Setup1).l
- ; ---------------------------------------------------------------------------
- BossRobot_Setup2:
- move.w (Player_1+$10).w,d0
- sub.w $10(a0),d0
- asl.w #4,d0
- move.w d0,$18(a0)
- BossRobot_Setup:
- jsr (Swing_UpAndDown).l
- jsr (MoveSprite2).l
- jmp (Obj_Wait).l
- ; =============== S U B R O U T I N E =======================================
- BossRobot_Robotnik_Intro:
- move.l #BossRobot_Robotnik_Intro_Locret,$34(a0)
- lea ChildObjDat_Robotnik_Intro(pc),a2
- jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- BossRobot_Robotnik_Intro_FindRobotnik_Start:
- sfx sfx_Boom,0,0,0
- move.w #$F,$2E(a0)
- move.l #BossRobot_Robotnik_Intro_FindRobotnik,$34(a0)
- rts
- ; ---------------------------------------------------------------------------
- BossRobot_Robotnik_Intro_FindRobotnik:
- movea.w $44(a0),a1
- move.w $10(a1),d0
- sub.w $10(a0),d0
- subq.w #8,d0
- bne.s +
- move.l #BossRobot_Robotnik_Intro_Locret,$34(a0)
- + asl.w #4,d0
- move.w d0,$18(a0)
- BossRobot_Robotnik_Intro_Locret:
- rts
- ; =============== S U B R O U T I N E =======================================
- BossRobot_Startup:
- move.b #BossRobot_Hits,$29(a0)
- move.w #$4F,$2E(a0)
- BossRobot_SetSubroutine:
- moveq #0,d0
- move.b $30(a0),d0
- addq.b #1,$30(a0)
- lea BossRobot_SetMovement(pc),a1
- cmpi.b #BossRobot_Hits/2,$29(a0)
- bhs.s +
- lea BossRobot_SetMovement2(pc),a1
- + move.b (a1,d0.w),d0
- bpl.s +
- clr.b $30(a0)
- bra.s BossRobot_Startup_Locret
- ; ---------------------------------------------------------------------------
- + lsl.w #2,d0
- move.l BossRobot_Movement(pc,d0.w),$34(a0)
- move.b #_Setup1,5(a0)
- clr.w $18(a0)
- clearRAM3 Pos_objtable_Start, Pos_objtable_End
- BossRobot_Startup_Locret:
- rts
- ; ---------------------------------------------------------------------------
- BossRobot_SetMovement:
- dc.b 0
- dc.b 2
- dc.b 1
- dc.b 2
- dc.b 0
- dc.b 3
- dc.b 2
- dc.b 1
- dc.b 2
- dc.b 0
- dc.b 3
- dc.b 1
- dc.w -1 ; Конец
- BossRobot_SetMovement2:
- dc.b 4
- dc.b 2
- dc.b 3
- dc.b 2
- dc.b 5
- dc.b 4
- dc.b 3
- dc.b 2
- dc.b 5
- dc.b 3
- dc.w -1 ; Конец
- BossRobot_Movement:
- dc.l BossRobot_MoveFallingBall_Start ; 0
- dc.l BossRobot_MoveCircularChaseBall_Start ; 1
- dc.l BossRobot_MoveRepulsionBall_Start ; 2
- dc.l BossRobot_MoveShootingBall_Start ; 3
- ; Extra
- dc.l BossRobot_MoveFallingWaitBall_Start ; 4
- dc.l BossRobot_MoveSwingBall_Start ; 5
- ; ---------------------------------------------------------------------------
- ; Босс атакует с помощью падающего шара
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossRobot_MoveFallingBall_Start:
- move.b #8,$39(a0)
- BossRobot_MoveFallingBall_FindSonic:
- move.b #_Setup2,5(a0)
- move.w #$1F,$2E(a0)
- move.l #BossRobot_MoveFallingBall_Attack,$34(a0)
- moveq #sfx_Boom,d0
- jmp (Play_Sound_2).l
- ; ---------------------------------------------------------------------------
- BossRobot_MoveFallingBall_Attack:
- move.b #_Setup1,5(a0)
- move.w #0,$18(a0)
- move.w #$1F,$2E(a0)
- move.l #BossRobot_MoveFallingBall_FindSonic,$34(a0)
- subq.b #1,$39(a0)
- bne.s +
- move.l #BossRobot_SetSubroutine,$34(a0)
- + lea ChildObjDat_FallingBall(pc),a2
- jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- ; Босс атакует с помощью циркулирующих шаров
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossRobot_MoveCircularChaseBall_Start:
- move.l #BossRobot_MoveCircularChaseBall_CheckPosition,$34(a0)
- sfx sfx_Boom,0,0,0
- BossRobot_MoveCircularChaseBall_CheckPosition:
- move.w (Camera_X_pos).w,d0
- addi.w #$A0,d0
- sub.w $10(a0),d0
- bne.s +
- move.l #BossRobot_MoveCircularChaseBall_Create,$34(a0)
- + asl.w #4,d0
- move.w d0,$18(a0)
- BossRobot_MoveCircularChaseBall_Wait:
- rts
- ; ---------------------------------------------------------------------------
- BossRobot_MoveCircularChaseBall_Create:
- move.l #BossRobot_MoveCircularChaseBall_Wait,$34(a0)
- lea ChildObjDat_CircularBall(pc),a2
- jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- BossRobot_MoveCircularChaseBall_SetMove:
- move.l #BossRobot_MoveCircularChaseBall_Move,$34(a0)
- move.w (RNG_seed).w,d0
- move.w #$80,$18(a0)
- andi.w #1,d0
- bne.s BossRobot_MoveCircularChaseBall_Move
- neg.w $18(a0)
- BossRobot_MoveCircularChaseBall_Move:
- move.w (Camera_X_pos).w,d0
- tst.w $18(a0)
- bpl.s +
- addi.w #$40,d0 ; Проверить левую сторону
- cmp.w $10(a0),d0
- bhs.s ++
- bra.s +++
- + addi.w #$100,d0 ; Проверить правую сторону
- cmp.w $10(a0),d0
- bhs.s ++
- + neg.w $18(a0)
- + rts
- ; ---------------------------------------------------------------------------
- ; Босс атакует с помощью отталкивающихся шаров
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossRobot_MoveRepulsionBall_Start:
- move.l #BossRobot_MoveRepulsionBall_CheckPosition,$34(a0)
- sfx sfx_Boom,0,0,0
- move.w (RNG_seed).w,d0
- andi.w #6,d0
- move.w d0,$3C(a0)
- move.w BossRobot_SetPos(pc,d0.w),$3A(a0)
- BossRobot_MoveRepulsionBall_CheckPosition:
- move.w (Camera_X_pos).w,d0
- add.w $3A(a0),d0
- sub.w $10(a0),d0
- bne.s +
- move.l #BossRobot_MoveRepulsionBall_Create,$34(a0)
- + asl.w #4,d0
- move.w d0,$18(a0)
- BossRobot_MoveRepulsionBall_Wait:
- rts
- ; ---------------------------------------------------------------------------
- BossRobot_SetPos:
- dc.w $40 ; Левая сторона
- dc.w $A0 ; Середина
- dc.w $100 ; Правая сторона
- dc.w $A0 ; Середина
- BossRobot_SetPos2:
- dc.w -$40 ; Левая сторона
- dc.w -$40 ; Середина
- dc.w $180 ; Правая сторона
- dc.w $180 ; Середина
- BossRobot_SetPos3:
- dc.w $40 ; Левая сторона
- dc.w $40 ; Середина
- dc.w $100 ; Правая сторона
- dc.w $100 ; Середина
- ; ---------------------------------------------------------------------------
- BossRobot_MoveRepulsionBall_Create:
- move.w #$3F,$2E(a0)
- move.l #BossRobot_MoveRepulsionBall_SetHidePosition,$34(a0)
- lea ChildObjDat_RepulsionBall(pc),a2
- jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- BossRobot_MoveRepulsionBall_SetHidePosition:
- move.b #setClose,$20(a0)
- sfx sfx_Boom,0,0,0
- move.l #BossRobot_MoveRepulsionBall_HidePosition,$34(a0)
- move.w $3C(a0),d0
- move.w BossRobot_SetPos2(pc,d0.w),$3A(a0)
- BossRobot_MoveRepulsionBall_HidePosition:
- move.w (Camera_X_pos).w,d0
- add.w $3A(a0),d0
- sub.w $10(a0),d0
- bne.s +
- move.l #BossRobot_MoveRepulsionBall_Wait,$34(a0)
- + asl.w #4,d0
- move.w d0,$18(a0)
- rts
- ; ---------------------------------------------------------------------------
- BossRobot_MoveRepulsionBall_SetReturnPosition:
- sfx sfx_Boom,0,0,0
- move.l #BossRobot_MoveRepulsionBall_ReturnPosition,$34(a0)
- move.w $3C(a0),d0
- move.w BossRobot_SetPos3(pc,d0.w),$3A(a0)
- BossRobot_MoveRepulsionBall_ReturnPosition:
- move.w (Camera_X_pos).w,d0
- add.w $3A(a0),d0
- sub.w $10(a0),d0
- bne.s +
- move.l #BossRobot_SetSubroutine,$34(a0)
- + asl.w #4,d0
- move.w d0,$18(a0)
- rts
- ; ---------------------------------------------------------------------------
- ; Босс атакует с помощью циркулирующих шаров
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossRobot_MoveShootingBall_Start:
- move.w (Camera_X_pos).w,d0
- addi.w #$A0,d0
- move.w #$40,$3A(a0)
- sub.w $10(a0),d0
- bgt.s +
- move.w #$100,$3A(a0)
- + move.l #BossRobot_MoveShootingBall_CheckPosition,$34(a0)
- sfx sfx_Boom,0,0,0
- BossRobot_MoveShootingBall_CheckPosition:
- move.w (Camera_X_pos).w,d0
- add.w $3A(a0),d0
- sub.w $10(a0),d0
- bne.s +
- move.l #BossRobot_MoveShootingBall_Create,$34(a0)
- + asl.w #4,d0
- move.w d0,$18(a0)
- rts
- ; ---------------------------------------------------------------------------
- BossRobot_MoveShootingBall_Create:
- move.w $3A(a0),d0
- move.w #-$40,d1
- cmpi.w #$100,d0
- bne.s +
- move.w #$180,d1
- + move.w d1,$3A(a0)
- move.w #$6F,$2E(a0)
- move.l #BossRobot_MoveShootingBall_HidePosition,$34(a0)
- lea ChildObjDat_ShootingBall(pc),a2
- jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- BossRobot_MoveShootingBall_HidePosition:
- move.w (Camera_X_pos).w,d0
- add.w $3A(a0),d0
- sub.w $10(a0),d0
- bne.s +
- move.l #BossRobot_MoveShootingBall_Wait,$34(a0)
- + asl.w #4,d0
- move.w d0,$18(a0)
- BossRobot_MoveShootingBall_Wait:
- rts
- ; ---------------------------------------------------------------------------
- BossRobot_MoveShootingBall_SetReturnPosition:
- sfx sfx_Boom,0,0,0
- move.l #BossRobot_MoveRepulsionBall_ReturnPosition,$34(a0)
- move.w $3A(a0),d0
- move.w #$40,d1
- cmpi.w #$180,d0
- bne.s +
- move.w #$100,d1
- + move.w d1,$3A(a0)
- rts
- ; ---------------------------------------------------------------------------
- ; Выстрел кучей падающих шаров
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossRobot_MoveFallingWaitBall_Start:
- move.w (Camera_X_pos).w,d0
- addi.w #$A0,d0
- move.w #$40,$3A(a0)
- sub.w $10(a0),d0
- bgt.s +
- move.w #$100,$3A(a0)
- + move.l #BossRobot_MoveFallingWaitBall_CheckPosition,$34(a0)
- sfx sfx_Boom,0,0,0
- BossRobot_MoveFallingWaitBall_CheckPosition:
- move.w (Camera_X_pos).w,d0
- add.w $3A(a0),d0
- sub.w $10(a0),d0
- bne.s +
- move.w #$DF,$2E(a0)
- move.b #setOpen,$20(a0)
- lea ChildObjDat_FallingWaitBall_Intro(pc),a2
- jsr (CreateChild6_Simple).l
- move.l #BossRobot_MoveFallingWaitBall_SetHidePosition,$34(a0)
- + asl.w #4,d0
- move.w d0,$18(a0)
- rts
- ; ---------------------------------------------------------------------------
- BossRobot_MoveFallingWaitBall_SetHidePosition:
- move.w (Camera_X_pos).w,d0
- addi.w #$A0,d0
- move.w #-$40,$3A(a0)
- sub.w $10(a0),d0
- bgt.s +
- move.w #$180,$3A(a0)
- + move.b #setClose,$20(a0)
- move.l #BossRobot_MoveFallingWaitBall_CheckHidePosition,$34(a0)
- sfx sfx_Boom,0,0,0
- BossRobot_MoveFallingWaitBall_CheckHidePosition:
- move.w (Camera_X_pos).w,d0
- add.w $3A(a0),d0
- sub.w $10(a0),d0
- bne.s +
- move.b #3,$39(a0)
- move.w #$F,$2E(a0)
- move.l #BossRobot_MoveFallingWaitBall_Create,$34(a0)
- + asl.w #4,d0
- move.w d0,$18(a0)
- rts
- ; ---------------------------------------------------------------------------
- BossRobot_MoveFallingWaitBall_Create:
- move.w #$EF,$2E(a0)
- bsr.s BossRobot_MoveFallingWaitBall_CreateBallAim
- subq.b #1,$39(a0)
- bne.s BossRobot_MoveFallingWaitBall_Locret
- move.l #BossRobot_MoveFallingWaitBall_Return,$34(a0)
- BossRobot_MoveFallingWaitBall_Locret:
- rts
- ; ---------------------------------------------------------------------------
- BossRobot_MoveFallingWaitBall_CreateBallAim:
- move.w (RNG_seed).w,d0
- andi.w #$E,d0
- move.w ObjDat_FallingWaitBall_Xpos_Random(pc,d0.w),$3C(a0)
- lea ObjDat_FallingWaitBall_Xpos(pc),a2
- cmpi.w #$90,$3C(a0)
- blo.s +
- lea ObjDat_FallingWaitBall_Xpos_Negative(pc),a2
- + moveq #0,d2
- move.w #9-1,d1
- - jsr (Create_New_Sprite3).l
- bne.s +
- move.l #Obj_FallingWaitBall,(a1)
- move.w a0,$46(a1)
- - move.w (a2)+,d0
- cmp.w $3C(a0),d0
- beq.s -
- add.w (Camera_X_pos).w,d0
- move.w d0,$10(a1)
- move.w (Camera_Y_pos).w,d0
- subi.w #$20,d0
- move.w d0,$14(a1)
- move.b d2,$2C(a1)
- addq.w #2,d2
- dbf d1,--
- move.w $3C(a0),$3E(a1)
- + rts
- ; ---------------------------------------------------------------------------
- ObjDat_FallingWaitBall_Xpos_Random:
- dc.w $50
- dc.w $F0
- dc.w $90
- dc.w $B0
- dc.w $70
- dc.w $110
- dc.w $30
- dc.w $D0
- ObjDat_FallingWaitBall_Xpos:
- dc.w $10
- dc.w $30
- dc.w $50
- dc.w $70
- dc.w $90
- dc.w $B0
- dc.w $D0
- dc.w $F0
- dc.w $110
- dc.w $130
- ObjDat_FallingWaitBall_Xpos_Negative:
- dc.w $130
- dc.w $110
- dc.w $F0
- dc.w $D0
- dc.w $B0
- dc.w $90
- dc.w $70
- dc.w $50
- dc.w $30
- dc.w $10
- ; ---------------------------------------------------------------------------
- BossRobot_MoveFallingWaitBall_Return:
- move.w (Camera_X_pos).w,d0
- addi.w #$A0,d0
- move.w #$40,$3A(a0)
- sub.w $10(a0),d0
- bgt.s +
- move.w #$100,$3A(a0)
- + move.b #setClose,$20(a0)
- move.l #BossRobot_MoveFallingWaitBall_CheckReturnPosition,$34(a0)
- sfx sfx_Boom,0,0,0
- BossRobot_MoveFallingWaitBall_CheckReturnPosition:
- move.w (Camera_X_pos).w,d0
- add.w $3A(a0),d0
- sub.w $10(a0),d0
- bne.s +
- move.w #$F,$2E(a0)
- move.l #BossRobot_SetSubroutine,$34(a0)
- + asl.w #4,d0
- move.w d0,$18(a0)
- rts
- ; ---------------------------------------------------------------------------
- ; Выстрел кучей падающих шаров
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossRobot_MoveSwingBall_Start:
- move.b #8,$39(a0)
- BossRobot_MoveSwingBall_FindSonic:
- move.b #_Setup2,5(a0)
- move.w #$1F,$2E(a0)
- move.l #BossRobot_MoveSwingBall_Attack,$34(a0)
- clearRAM3 Pos_objtable_Start, Pos_objtable_End
- moveq #sfx_Boom,d0
- jmp (Play_Sound_2).l
- ; ---------------------------------------------------------------------------
- BossRobot_MoveSwingBall_Attack:
- move.b #_Setup1,5(a0)
- move.w #0,$18(a0)
- move.w #$5F,$2E(a0)
- move.l #BossRobot_MoveSwingBall_FindSonic,$34(a0)
- subq.b #1,$39(a0)
- bne.s +
- move.l #BossRobot_SetSubroutine,$34(a0)
- + lea ChildObjDat_SwingBall(pc),a2
- jmp (CreateChild1_Normal).l
- ; ---------------------------------------------------------------------------
- ; Проверка урона
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossRobot_CheckTouch:
- tst.b $28(a0)
- bne.s BossRobot_CheckTouch_Locret
- move.b $29(a0),d0
- beq.s BossRobot_CheckTouch_Explosive
- tst.b $1C(a0)
- bne.s +
- move.b #$80,$1C(a0)
- sfx sfx_HitBoss,0,0,0
- cmpi.b #BossRobot_Hits/2-1,d0
- bne.s +
- clr.b $30(a0)
- + moveq #0,d0
- btst #0,$1C(a0)
- bne.s +
- addi.w #6*2,d0
- + bsr.w BossRobot_PalFlash
- subq.b #1,$1C(a0)
- bne.s BossRobot_CheckTouch_Locret
- move.b $25(a0),$28(a0)
- BossRobot_CheckTouch_Locret:
- rts
- ; ---------------------------------------------------------------------------
- BossRobot_CheckTouch_Explosive:
- move.l #Wait_NewDelay,(a0)
- bset #7,$2A(a0)
- clr.l $18(a0)
- move.l #BossRobot_CheckTouch_Explosive_SetFalling,$34(a0)
- lea (Child6_CreateBossExplosion).l,a2
- jsr (CreateChild6_Simple).l
- jmp (BossDefeated).l
- ; ---------------------------------------------------------------------------
- BossRobot_CheckTouch_Explosive_SetFalling:
- addq.b #2,(Dynamic_resize_routine).w
- move.l #BossRobot_CheckTouch_Explosive_Falling,(a0)
- BossRobot_CheckTouch_Explosive_Falling:
- jsr (MoveSprite_LightGravity).l
- jsr (Draw_Sprite).l
- jsr (ObjHitFloor).l
- tst.w d1
- bpl.s BossRobot_CheckTouch_Locret
- add.w d1,$14(a0)
- bclr #7,4(a0)
- move.l #Go_Delete_Sprite_2,(a0)
- sfx sfx_WallSmash,0,0,0
- lea ChildObjDat_BossRobot_FlickerMove(pc),a2
- jsr (CreateChild6_Simple).l
- lea ChildObjDat_RobotnikJetpack_Intro(pc),a2
- jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- ; Тень
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_ChasingBall_Trail:
- moveq #0,d0
- move.b $2C(a0),d0
- lsl.w #4,d0
- addi.b #$24,d0
- move.b d0,$2C(a0)
- lea ObjDat3_ChasingBall_Trail(pc),a1
- jsr (SetUp_ObjAttributes3).l
- move.l #+,(a0)
- + jsr (Child_GetVRAMPriorityOnce).l
- jsr Obj_ChasingBall_CopyPos(pc)
- jmp (Child_DrawTouch_Sprite_Explosion).l
- ; ---------------------------------------------------------------------------
- ; Тень 2
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_ChasingBall_Trail_2:
- moveq #0,d0
- move.b $2C(a0),d0
- lsl.w #4,d0
- addi.b #$24,d0
- move.b d0,$2C(a0)
- lea ObjDat3_ChasingBall_Trail(pc),a1
- jsr (SetUp_ObjAttributes3).l
- move.l #+,(a0)
- + jsr (Child_GetVRAMPriorityOnce).l
- jsr Obj_ChasingBall_CopyPos2(pc)
- jmp (Child_DrawTouch_Sprite_Explosion).l
- ; ---------------------------------------------------------------------------
- ; Тень отталкивающегося шара
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_RepulsionBall_Trail:
- moveq #0,d0
- move.b $2C(a0),d0
- lsl.w #3,d0
- addi.w #$14,d0
- move.b d0,$2C(a0)
- lea ObjDat3_ChasingBall_Trail(pc),a1
- jsr (SetUp_ObjAttributes3).l
- move.l #+,(a0)
- + jsr Obj_ChasingBall_CopyPos(pc)
- jmp (Child_DrawTouch_Sprite_Explosion).l
- ; ---------------------------------------------------------------------------
- ; Падающий шар
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_FallingBall:
- moveq #0,d0
- move.b obRoutine(a0),d0
- move.w FallingBall_Index(pc,d0.w),d0
- jsr FallingBall_Index(pc,d0.w)
- jmp (Child_DrawTouch_Sprite_CircularExplosion).l
- ; ---------------------------------------------------------------------------
- FallingBall_Index: offsetTable
- offsetTableEntry.w FallingBall_Init ; 0
- offsetTableEntry.w FallingBall_Setup ; 2
- ; ---------------------------------------------------------------------------
- FallingBall_Init:
- lea ObjDat3_ChasingBall(pc),a1
- jsr (SetUp_ObjAttributes).l
- movea.w $46(a0),a1
- move.b #setOpen,$20(a1)
- move.l #FallingBall_Explosion,$34(a0)
- move.l #AniRaw_ChasingBall,$30(a0)
- FallingBall_Setup:
- jsr (Animate_Raw).l
- jsr (MoveSprite).l
- jmp (ObjHitFloor_DoRoutine).l
- ; ---------------------------------------------------------------------------
- FallingBall_Explosion:
- movea.w $46(a0),a1
- move.b #setClose,$20(a1)
- FallingWaitBall_Explosion:
- sfx sfx_BreakBridge,0,0,0
- move.l #Go_Delete_Sprite,$34(a0)
- move.w #$14,(Screen_Shaking_Flag).w
- lea ChildObjDat_DEZExplosion(pc),a2
- jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- ; Вращающийся и преследующий шар
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_CircularChaseBall:
- moveq #0,d0
- move.b obRoutine(a0),d0
- move.w CircularChaseBall_Index(pc,d0.w),d0
- jsr CircularChaseBall_Index(pc,d0.w)
- bsr.w CircularChaseBall_SetTrail
- jmp (Child_DrawTouch_Sprite_CircularExplosion).l
- ; ---------------------------------------------------------------------------
- CircularChaseBall_Index: offsetTable
- offsetTableEntry.w CircularChaseBall_Init ; 0
- offsetTableEntry.w CircularChaseBall_Setup ; 2
- offsetTableEntry.w CircularChaseBall_Setup2 ; 4
- offsetTableEntry.w CircularChaseBall_Setup3 ; 6
- ; ---------------------------------------------------------------------------
- CircularChaseBall_Init:
- lea ObjDat3_ChasingBall(pc),a1
- jsr (SetUp_ObjAttributes).l
- move.b #2,$3A(a0)
- move.b #2,$40(a0)
- move.w #$1F,$2E(a0)
- tst.b $2C(a0)
- beq.s +
- move.w #$5F,$2E(a0)
- + move.l #CircularChaseBall_MoveDown,$34(a0)
- move.l #AniRaw_ChasingBall,$30(a0)
- lea ChildObjDat_ChasingBall_Trail2(pc),a2
- tst.b $2C(a0)
- bne.s +
- movea.w $46(a0),a1
- move.b #setOpen,$20(a1)
- sfx sfx_Laser2,0,0,0
- lea ChildObjDat_ChasingBall_Trail(pc),a2
- + jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- CircularChaseBall_Setup3:
- jsr (Find_SonicTails).l
- jsr (Change_FlipX).l
- move.w #$400,d0
- moveq #$20,d1
- jsr (Chase_Object).l
- bra.s CircularChaseBall_Setup
- ; ---------------------------------------------------------------------------
- CircularChaseBall_Setup2:
- move.b $40(a0),d0
- add.b d0,$3C(a0)
- move.b $3A(a0),d2
- jsr (MoveSprite_CircularSimple).l
- CircularChaseBall_Setup:
- jsr (Animate_Raw).l
- jsr (MoveSprite2).l
- jmp (Obj_Wait).l
- ; ---------------------------------------------------------------------------
- CircularChaseBall_MoveDown:
- move.w #$100,$1A(a0)
- move.w #$3F,$2E(a0)
- move.l #CircularChaseBall_MoveClosed,$34(a0)
- rts
- ; ---------------------------------------------------------------------------
- CircularChaseBall_MoveClosed:
- move.b #_Setup2,5(a0)
- clr.w $1A(a0)
- ori.w #$C000,$A(a0)
- move.w #$9F,$2E(a0)
- move.l #CircularChaseBall_SetChase,$34(a0)
- tst.b $2C(a0)
- beq.s +
- movea.w $46(a0),a1
- move.b #setClose,$20(a1)
- move.w #$2EF,$2E(a0)
- move.w #$4F,$2E(a1)
- move.l #BossRobot_MoveCircularChaseBall_SetMove,$34(a1)
- + rts
- ; ---------------------------------------------------------------------------
- CircularChaseBall_SetChase:
- move.w #$19F,$2E(a0)
- move.l #CircularChaseBall_Remove,$34(a0)
- move.b #_Setup3,5(a0)
- moveq #sfx_Flash,d0
- jmp (Play_Sound_2).l
- ; ---------------------------------------------------------------------------
- CircularChaseBall_Remove:
- tst.b $2C(a0)
- beq.s +
- movea.w $46(a0),a1
- move.w #$4F,$2E(a1)
- move.l #BossRobot_SetSubroutine,$34(a1)
- + move.l #Go_Delete_Sprite,(a0)
- lea ChildObjDat_DEZCircularExplosion(pc),a2
- jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- CircularChaseBall_SetTrail:
- moveq #0,d0
- move.b $2C(a0),d0
- add.w d0,d0
- jmp CircularChaseBall_TrailIndex(pc,d0.w)
- ; ---------------------------------------------------------------------------
- CircularChaseBall_TrailIndex:
- bra.w Obj_ChasingBall_SendPos
- bra.w Obj_ChasingBall_SendPos2
- ; ---------------------------------------------------------------------------
- ; Отталкивающийся шар
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_RepulsionBall:
- moveq #0,d0
- move.b obRoutine(a0),d0
- move.w RepulsionBall_Index(pc,d0.w),d0
- jsr RepulsionBall_Index(pc,d0.w)
- jsr Obj_ChasingBall_SendPos(pc)
- jmp (Child_DrawTouch_Sprite_Explosion).l
- ; ---------------------------------------------------------------------------
- RepulsionBall_Index: offsetTable
- offsetTableEntry.w RepulsionBall_Init ; 0
- offsetTableEntry.w RepulsionBall_Setup ; 2
- offsetTableEntry.w RepulsionBall_Setup2 ; 4
- ; ---------------------------------------------------------------------------
- RepulsionBall_Init:
- lea ObjDat3_ShootingBall_Missile(pc),a1
- jsr (SetUp_ObjAttributes).l
- move.w #$400,$1A(a0)
- move.l #Repulsion_CheckTouch,$34(a0)
- movea.w $46(a0),a1
- move.b #setOpen,$20(a1)
- sfx sfx_Laser,0,0,0
- lea ChildObjDat_RepulsionBall_Trail(pc),a2
- jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- RepulsionBall_Setup:
- jsr (MoveSprite2).l
- jmp (ObjHitFloor_DoRoutine).l
- ; ---------------------------------------------------------------------------
- RepulsionBall_Setup2:
- jsr Repulsion_CheckWall(pc)
- jsr (MoveSprite2).l
- jmp (Obj_Wait).l
- ; ---------------------------------------------------------------------------
- Repulsion_CheckTouch:
- move.b #_Setup2,5(a0)
- move.w #9*60,$2E(a0)
- move.l #Repulsion_Remove,$34(a0)
- move.w (RNG_seed).w,d0
- move.w d0,d1
- andi.w #$C,d0
- move.l ObDat_RepulsionSpeed(pc,d0.w),$18(a0)
- andi.w #1,d1
- bne.s +
- neg.l $18(a0)
- + rts
- ; ---------------------------------------------------------------------------
- ObDat_RepulsionSpeed:
- dc.w $400, $600 ; Xpos, Ypos
- dc.w $100, $600 ; Xpos, Ypos
- dc.w $400, $100 ; Xpos, Ypos
- dc.w $400, $600 ; Xpos, Ypos
- ; ---------------------------------------------------------------------------
- Repulsion_Remove:
- movea.w $46(a0),a1
- move.w #$F,$2E(a1)
- move.l #BossRobot_MoveRepulsionBall_SetReturnPosition,$34(a1)
- move.l #Go_Delete_Sprite,(a0)
- rts
- ; ---------------------------------------------------------------------------
- Repulsion_CheckWall:
- move.w (Camera_Y_pos).w,d0
- tst.w $1A(a0)
- bmi.s +
- addi.w #$C8,d0 ; Проверить пол
- cmp.w $14(a0),d0
- blo.s ++
- bra.s +++
- + addi.w #$18,d0 ; Проверить потолок
- cmp.w $14(a0),d0
- blo.s ++
- + neg.w $1A(a0)
- sfx sfx_Laser5,0,0,0
- + move.w (Camera_X_pos).w,d0
- tst.w $18(a0)
- bpl.s +
- addq.w #8,d0 ; Проверить левую сторону стены
- cmp.w $10(a0),d0
- bhs.s ++
- bra.s +++
- + addi.w #$138,d0 ; Проверить правую сторону стены
- cmp.w $10(a0),d0
- bhs.s ++
- + neg.w $18(a0)
- sfx sfx_Laser5,0,0,0
- + rts
- ; ---------------------------------------------------------------------------
- ; Стреляющий по радиусу шар
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_ShootingBall:
- moveq #0,d0
- move.b obRoutine(a0),d0
- move.w ShootingBall_Index(pc,d0.w),d0
- jsr ShootingBall_Index(pc,d0.w)
- jmp (Child_DrawTouch_Sprite_CircularExplosion).l
- ; ---------------------------------------------------------------------------
- ShootingBall_Index: offsetTable
- offsetTableEntry.w ShootingBall_Init ; 0
- offsetTableEntry.w ShootingBall_Setup ; 2
- offsetTableEntry.w ShootingBall_Setup2 ; 4
- offsetTableEntry.w ShootingBall_Setup3 ; 6
- ; ---------------------------------------------------------------------------
- ShootingBall_Init:
- lea ObjDat3_ChasingBall(pc),a1
- jsr (SetUp_ObjAttributes).l
- movea.w $46(a0),a1
- move.b #setOpen,$20(a1)
- move.b #12,y_radius(a0)
- move.l #ShootingBall_SetBounced,$34(a0)
- move.l #AniRaw_ChasingBall,$30(a0)
- move.w (RNG_seed).w,d0
- andi.w #1,d0
- bne.s +
- not.w d0
- + move.b d0,$40(a0)
- sfx sfx_Laser,0,0,0
- ShootingBall_Locret:
- rts
- ; ---------------------------------------------------------------------------
- ShootingBall_Setup:
- jsr (Animate_Raw).l
- jsr (MoveSprite).l
- jmp (ObjHitFloor_DoRoutine).l
- ; ---------------------------------------------------------------------------
- ShootingBall_Setup3:
- jsr ShootingBall_Shoot(pc)
- ShootingBall_Setup2:
- jsr (Animate_Raw).l
- jsr (MoveSprite2).l
- jmp (Obj_Wait).l
- ; ---------------------------------------------------------------------------
- ShootingBall_SetBounced:
- movea.w $46(a0),a1
- move.b #setClose,$20(a1)
- move.l #ShootingBall_CheckBounced,$34(a0)
- move.w #$100,$18(a0)
- cmpi.w #$180,$3A(a1)
- bne.s ShootingBall_CheckBounced
- neg.w $18(a0)
- ShootingBall_CheckBounced:
- move.w $1A(a0),d0
- bmi.s ShootingBall_Locret
- cmpi.w #$180,d0
- bhs.s ShootingBall_Fall
- move.b #_Setup2,5(a0)
- move.l #ShootingBall_CheckPosition,$34(a0)
- sfx sfx_Squeak,0,0,0
- lea ChildObjDat_DEZGravitySwitch(pc),a2
- jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- ShootingBall_Fall:
- asr.w d0
- neg.w d0
- move.w d0,$1A(a0)
- moveq #sfx_Emerald,d0
- jmp (Play_Sound_2).l
- ; ---------------------------------------------------------------------------
- ShootingBall_CheckPosition:
- move.w (Camera_X_pos).w,d0
- addi.w #$A0,d0
- sub.w $10(a0),d0
- asl.w #4,d0
- move.w d0,$18(a0)
- move.w (Camera_Y_pos).w,d0
- addi.w #$70,d0
- sub.w $14(a0),d0
- bne.s +
- move.b #_Setup3,5(a0)
- move.w #16*60,$2E(a0)
- move.l #ShootingBall_Remove,$34(a0)
- + asl.w #4,d0
- move.w d0,$1A(a0)
- rts
- ; ---------------------------------------------------------------------------
- ShootingBall_Remove:
- movea.w $46(a0),a1
- move.w #$F,$2E(a1)
- sfx sfx_BreakBridge,0,0,0
- move.l #BossRobot_MoveShootingBall_SetReturnPosition,$34(a1)
- move.l #Obj_DEZCircularExplosion,(a0)
- ShootingBall_Remove_Locret:
- rts
- ; ---------------------------------------------------------------------------
- ShootingBall_Shoot:
- move.b $40(a0),d0
- add.b d0,$3C(a0)
- moveq #sfx_Fire,d0
- jsr (Wait_Play_Sound).l
- btst #0,(Level_frame_counter+1).w
- beq.s ShootingBall_Remove_Locret
- lea ChildObjDat_ShootingBall_Missile(pc),a2
- jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- ; Снаряд для выстрела по радиусу
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_ShootingBall_Missile:
- moveq #0,d0
- move.b $2C(a0),d0
- lsl.w #6,d0
- move.b d0,$3F(a0)
- lea ObjDat3_ShootingBall_Missile(pc),a1
- jsr (SetUp_ObjAttributes).l
- move.l #+,(a0)
- movea.w $46(a0),a1
- move.b $3C(a1),d0
- add.b $3F(a0),d0
- jsr (GetSineCosine).l
- move.w #$C00,d2
- muls.w d2,d0
- asr.l #8,d0
- move.w d0,$18(a0)
- muls.w d2,d1
- asr.l #8,d1
- move.w d1,$1A(a0)
- + jsr (MoveSprite2).l
- bsr.s ShootingBall_Missile_CheckFloor
- jmp (Sprite_ChildCheckDeleteTouchXY).l
- ; ---------------------------------------------------------------------------
- ShootingBall_Missile_CheckFloor:
- move.w (Camera_Y_pos).w,d0
- addi.w #$10,d0
- cmp.w $14(a0),d0
- bhs.s +
- addi.w #$C0,d0
- cmp.w $14(a0),d0
- bhs.s ShootingBall_Missile_Locret
- + move.w #4,(Screen_Shaking_Flag).w
- btst #1,(Level_frame_counter+1).w
- beq.s ShootingBall_Missile_Locret
- move.l #loc_1E746,(a0)
- ShootingBall_Missile_Locret:
- rts
- ; ---------------------------------------------------------------------------
- ; Падающий ждущий шар (кат-сцена)
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_FallingWaitBall_Intro:
- moveq #0,d0
- move.b $2C(a0),d0
- lsl.w #2,d0
- addq.w #8,d0
- move.w d0,$2E(a0)
- lea ObjDat3_ChasingBall(pc),a1
- jsr (SetUp_ObjAttributes).l
- ori.w #$C000,$A(a0)
- move.w #$800,$1A(a0)
- move.l #+,(a0)
- move.l #FallingWaitBall_Intro_Sound,$34(a0)
- move.l #AniRaw_ChasingBall,$30(a0)
- + jsr (Animate_Raw).l
- jsr (Obj_Wait).l
- jmp (Sprite_ChildCheckDeleteTouchXY).l
- ; ---------------------------------------------------------------------------
- FallingWaitBall_Intro_Sound:
- move.l #MoveSprite2,$34(a0)
- moveq #sfx_Ghost,d0
- jmp (Play_Sound_2).l
- ; ---------------------------------------------------------------------------
- ; Падающий ждущий шар
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_FallingWaitBall:
- moveq #0,d0
- move.b obRoutine(a0),d0
- move.w FallingWaitBall_Index(pc,d0.w),d0
- jsr FallingWaitBall_Index(pc,d0.w)
- jmp (Child_DrawTouch_Sprite_CircularExplosion).l
- ; ---------------------------------------------------------------------------
- FallingWaitBall_Index: offsetTable
- offsetTableEntry.w FallingWaitBall_Init ; 0
- offsetTableEntry.w FallingWaitBall_Setup ; 2
- offsetTableEntry.w FallingWaitBall_Setup2 ; 4
- offsetTableEntry.w FallingWaitBall_Setup3 ; 6
- ; ---------------------------------------------------------------------------
- FallingWaitBall_Init:
- lea ObjDat3_ChasingBall(pc),a1
- jsr (SetUp_ObjAttributes).l
- ori.w #$C000,$A(a0)
- move.l #FallingWaitBall_Waiting,$34(a0)
- move.l #AniRaw_ChasingBall,$30(a0)
- move.b $2C(a0),d0
- lsl.w #2,d0
- addi.w #$20,d0
- move.w d0,$2E(a0)
- cmpi.b #$10,$2C(a0)
- bne.s +
- lea ChildObjDat_FallingWaitBall_Aim(pc),a2
- jsr (CreateChild6_Simple).l
- bne.s +
- move.w $3E(a0),$3E(a1)
- + rts
- ; ---------------------------------------------------------------------------
- FallingWaitBall_Setup:
- jsr (Animate_Raw).l
- jmp (Obj_Wait).l
- ; ---------------------------------------------------------------------------
- FallingWaitBall_Setup2:
- jsr (Animate_Raw).l
- jsr (MoveSprite).l
- jmp (Obj_Wait).l
- ; ---------------------------------------------------------------------------
- FallingWaitBall_Setup3:
- jsr (Animate_Raw).l
- jsr (MoveSprite).l
- jmp (ObjHitFloor_DoRoutine).l
- ; ---------------------------------------------------------------------------
- FallingWaitBall_Waiting:
- move.b #_Setup2,5(a0)
- move.w #$1F,$2E(a0)
- move.l #FallingWaitBall_Waiting2,$34(a0)
- tst.b $2C(a0)
- bne.s +
- sfx sfx_Falling,0,0,0
- + rts
- ; ---------------------------------------------------------------------------
- FallingWaitBall_Waiting2:
- move.b #_Setup3,5(a0)
- eori.w #$4000,$A(a0)
- move.l #FallingWaitBall_Explosion,$34(a0)
- rts
- ; ---------------------------------------------------------------------------
- ; Прицел для вращающегося и преследующего шара
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_FallingWaitBall_Aim:
- move.w (Camera_X_pos).w,d0
- add.w $3E(a0),d0
- move.w d0,$10(a0)
- move.w (Camera_Y_pos).w,d0
- add.w #$C8,d0
- move.w d0,$14(a0)
- sfx sfx_Squeak,0,0,0
- lea ObjDat3_FallingWaitBall_Aim(pc),a1
- jsr (SetUp_ObjAttributes).l
- move.w #$2F,$2E(a0)
- move.l #+,(a0)
- move.l #Go_Delete_Sprite,$34(a0)
- move.l #AniRaw_FallingWaitBall_Aim,$30(a0)
- + jsr (Animate_Raw).l
- jsr (Obj_Wait).l
- jmp (Draw_Sprite).l
- ; ---------------------------------------------------------------------------
- ; Раскачивающийся шар
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_SwingBall:
- moveq #0,d0
- move.b obRoutine(a0),d0
- move.w SwingBall_Index(pc,d0.w),d0
- jsr SwingBall_Index(pc,d0.w)
- bsr.w CircularChaseBall_SetTrail
- jmp (Sprite_ChildCheckDeleteTouchXY).l
- ; ---------------------------------------------------------------------------
- SwingBall_Index: offsetTable
- offsetTableEntry.w SwingBall_Init ; 0
- offsetTableEntry.w SwingBall_Setup ; 2
- offsetTableEntry.w SwingBall_Setup2 ; 4
- ; ---------------------------------------------------------------------------
- SwingBall_Init:
- lea ObjDat3_ChasingBall(pc),a1
- jsr (SetUp_ObjAttributes).l
- ori.w #$C000,$A(a0)
- move.w #$F,$2E(a0)
- move.l #SwingBall_MoveDown,$34(a0)
- move.l #AniRaw_ChasingBall,$30(a0)
- move.b #6,$40(a0)
- lea ChildObjDat_ChasingBall_Trail2(pc),a2
- tst.b $2C(a0)
- bne.s +
- neg.w $40(a0)
- movea.w $46(a0),a1
- move.b #setOpen,$20(a1)
- sfx sfx_Laser2,0,0,0
- lea ChildObjDat_ChasingBall_Trail(pc),a2
- + jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- SwingBall_Setup2:
- move.b $40(a0),d0
- add.b d0,$3C(a0)
- move.b $3C(a0),d0
- jsr (GetSineCosine).l
- asl.w #2,d0
- move.w d0,$18(a0)
- SwingBall_Setup:
- jsr (Animate_Raw).l
- jsr (MoveSprite2).l
- jmp (Obj_Wait).l
- ; ---------------------------------------------------------------------------
- SwingBall_MoveDown:
- move.b #_Setup2,5(a0)
- move.w #$300,$1A(a0)
- move.l #SwingBall_SetClose,$34(a0)
- SwingBall_SetClose:
- tst.b $2C(a0)
- bne.s SwingBall_Locret
- tst.b 4(a0)
- bmi.s SwingBall_Locret
- movea.w $46(a0),a1
- move.b #setClose,$20(a1)
- SwingBall_Locret:
- rts
- ; ---------------------------------------------------------------------------
- ; Взрывы
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_DEZExplosion:
- moveq #1,d2
- move.w #8-1,d1
- - jsr (Create_New_Sprite3).l
- bne.s +
- move.l #Obj_DEZExplosion_Anim,(a1)
- move.l #Map_BossDEZExplosion,$C(a1)
- move.w #$530,$A(a1)
- move.b #4,4(a1)
- move.w #$100,8(a1)
- move.b #$C,7(a1)
- move.b #$C,6(a1)
- move.w $10(a0),$10(a1)
- move.w $14(a0),$14(a1)
- move.w d2,d3
- asl.w #8,d3
- neg.w d3
- move.w d3,$1A(a1)
- move.b #3,$24(a1)
- move.b #$8B,$28(a1)
- addq.w #1,d2
- dbf d1,-
- + bra.s DEZExplosion_Delete
- ; ---------------------------------------------------------------------------
- Obj_DEZExplosion_Anim:
- subq.b #1,$24(a0)
- bpl.s +
- move.b #7,$24(a0)
- addq.b #1,$22(a0)
- cmpi.b #7,$22(a0)
- beq.s DEZExplosion_Delete
- cmpi.b #5,$22(a0)
- bne.s +
- move.b #0,$28(a0)
- + jsr (MoveSprite).l
- jmp (Draw_And_Touch_Sprite).l
- ; ---------------------------------------------------------------------------
- DEZExplosion_Delete:
- jmp (Delete_Current_Sprite).l
- ; =============== S U B R O U T I N E =======================================
- Obj_DEZCircularExplosion:
- moveq #0,d2
- move.w #8-1,d1
- - jsr (Create_New_Sprite3).l
- bne.s +
- move.l #Obj_DEZCircularExplosion_Anim,(a1)
- move.l #Map_BossDEZExplosion,$C(a1)
- move.w #$8530,$A(a1)
- move.b #4,4(a1)
- move.w #$100,8(a1)
- move.b #$C,7(a1)
- move.b #$C,6(a1)
- move.w $10(a0),$10(a1)
- move.w $14(a0),$14(a1)
- move.b #3,$24(a1)
- move.b #8,$3A(a1)
- move.b d2,$26(a1)
- move.b #8,$40(a1)
- addi.w #$20,d2
- dbf d1,-
- + bra.s DEZExplosion_Delete
- ; ---------------------------------------------------------------------------
- Obj_DEZCircularExplosion_Anim:
- subq.b #1,$24(a0)
- bpl.s +
- move.b #7,$24(a0)
- addq.b #1,$22(a0)
- subq.b #1,$3A(a0)
- cmpi.b #7,$22(a0)
- beq.w DEZExplosion_Delete
- + move.b $40(a0),d0
- sub.b d0,$26(a0)
- move.b $26(a0),d0
- jsr (GetSineCosine).l
- moveq #0,d2
- move.b $3A(a0),d2
- asr.w d2,d0
- add.w d0,$10(a0)
- asr.w d2,d1
- add.w d1,$14(a0)
- jmp (Draw_Sprite).l
- ; =============== S U B R O U T I N E =======================================
- Obj_BossRobot_FlickerMove:
- lea ObjDat3_BossRobot_Flicker(pc),a1
- jsr (SetUp_ObjAttributes3).l
- move.l #Obj_FlickerMove,(a0)
- moveq #0,d0
- move.b $2C(a0),d0
- lsr.b #1,d0
- addq.b #4,d0
- move.b d0,$22(a0)
- moveq #8,d0
- jsr (Set_IndexedVelocity).l
- jmp (Draw_Sprite).l
- ; =============== S U B R O U T I N E =======================================
- Obj_ChasingBall_SendPos:
- move.w (Pos_objtable_index).w,d0
- lea (Pos_objTable).w,a1
- lea (a1,d0.w),a1
- move.w x_pos(a0),(a1)+
- move.w y_pos(a0),(a1)+
- addq.b #4,(Pos_objtable_byte).w
- rts
- ; ---------------------------------------------------------------------------
- Obj_ChasingBall_SendPos2:
- move.w (Pos_obj2table_index).w,d0
- lea (Pos_obj2Table).w,a1
- lea (a1,d0.w),a1
- move.w x_pos(a0),(a1)+
- move.w y_pos(a0),(a1)+
- addq.b #4,(Pos_obj2table_byte).w
- rts
- ; ---------------------------------------------------------------------------
- Obj_ChasingBall_CopyPos:
- move.w (Pos_objtable_index).w,d0
- lea (Pos_objtable).w,a1
- bra.s Obj_ChasingBall_CopyPosSet
- ; ---------------------------------------------------------------------------
- Obj_ChasingBall_CopyPos2:
- move.w (Pos_obj2table_index).w,d0
- lea (Pos_obj2table).w,a1
- Obj_ChasingBall_CopyPosSet:
- sub.b $2C(a0),d0
- lea (a1,d0.w),a1
- move.w (a1)+,x_pos(a0)
- move.w (a1)+,y_pos(a0)
- rts
- ; =============== S U B R O U T I N E =======================================
- BossRobot_PalFlash:
- lea LoadBossRobot_PalRAM(pc),a1
- lea LoadBossRobot_PalCycle(pc,d0.w),a2
- jmp (CopyWordData_6).l
- ; ---------------------------------------------------------------------------
- LoadBossRobot_PalRAM:
- dc.w Normal_palette_line_2+6
- dc.w Normal_palette_line_2+8
- dc.w Normal_palette_line_2+$16
- dc.w Normal_palette_line_2+$18
- dc.w Normal_palette_line_2+$1A
- dc.w Normal_palette_line_2+$1C
- LoadBossRobot_PalCycle:
- dc.w $E, 8, $866, $644, $422, 0
- dc.w $888, $AAA, $888, $AAA, $CCC, $EEE
- ; =============== S U B R O U T I N E =======================================
- ObjDat3_BossRobot:
- dc.l Map_BossRobot
- dc.w $22B0
- dc.w $200
- dc.b 80/2
- dc.b 80/2
- dc.b 0
- dc.b $F
- ObjDat3_BossRobot_Flicker:
- dc.w 0
- dc.b 80/2
- dc.b 80/2
- dc.b 4
- dc.b 0
- ObjDat3_ChasingBall:
- dc.l Map_BossBall
- dc.w $2F0
- dc.w $280
- dc.b 32/2
- dc.b 24/2
- dc.b 1
- dc.b $82
- ObjDat3_ShootingBall_Missile:
- dc.l Map_BossBall
- dc.w $2F0
- dc.w $280
- dc.b 16/2
- dc.b 16/2
- dc.b 0
- dc.b $8B
- ObjDat3_ChasingBall_Trail:
- dc.w $280
- dc.b 16/2
- dc.b 16/2
- dc.b 0
- dc.b $8B
- ObjDat3_FallingWaitBall_Aim:
- dc.l Map_BossAim
- dc.w $E334
- dc.w 0
- dc.b 44/2
- dc.b 44/2
- dc.b 0
- dc.b 0
- AniRaw_ChasingBall:
- dc.b 1, 1, 2, 1, 5, $FC
- AniRaw_FallingWaitBall_Aim:
- dc.b 0, 0, 1, $FC
- ChildObjDat_ChasingBall_Trail:
- dc.w 4-1
- dc.l Obj_ChasingBall_Trail
- ChildObjDat_ChasingBall_Trail2:
- dc.w 4-1
- dc.l Obj_ChasingBall_Trail_2
- ChildObjDat_RepulsionBall_Trail:
- dc.w 12-1
- dc.l Obj_RepulsionBall_Trail
- ChildObjDat_FallingBall:
- dc.w 1-1
- dc.l Obj_FallingBall
- ChildObjDat_CircularBall:
- dc.w 2-1
- dc.l Obj_CircularChaseBall
- ChildObjDat_ShootingBall:
- dc.w 1-1
- dc.l Obj_ShootingBall
- ChildObjDat_ShootingBall_Missile:
- dc.w 2-1
- dc.l Obj_ShootingBall_Missile
- ChildObjDat_RepulsionBall:
- dc.w 1-1
- dc.l Obj_RepulsionBall
- ChildObjDat_FallingWaitBall_Aim:
- dc.w 1-1
- dc.l Obj_FallingWaitBall_Aim
- ChildObjDat_FallingWaitBall_Intro:
- dc.w 27-1
- dc.l Obj_FallingWaitBall_Intro
- ChildObjDat_SwingBall:
- dc.w 2-1
- dc.l Obj_SwingBall
- dc.b $16
- dc.b 0
- dc.l Obj_SwingBall
- dc.b -$16
- dc.b 0
- ChildObjDat_DEZCircularExplosion:
- dc.w 1-1
- dc.l Obj_DEZCircularExplosion
- ChildObjDat_DEZExplosion:
- dc.w 1-1
- dc.l Obj_DEZExplosion
- ChildObjDat_DEZGravitySwitch:
- dc.w 2-1
- dc.l Obj_DEZGravitySwitch
- ChildObjDat_BossRobot_FlickerMove:
- dc.w 6-1
- dc.l Obj_BossRobot_FlickerMove
- ; ---------------------------------------------------------------------------
- include "Objects/Boss/Object Data/Anim - Boss.asm"
- include "Objects/Boss/Object Data/Map - Boss.asm"
- include "Objects/Boss/Object Data/Map - Ball.asm"
- include "Objects/Boss/Object Data/Map - Aim.asm"
- include "Objects/Boss/Object Data/Map - Explosion.asm"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement