Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ; ---------------------------------------------------------------------------
- ; Босс-Neo Bahamut
- ; ---------------------------------------------------------------------------
- ; Hits
- BossNeoBahamut_Hits = 12
- ; Attributes
- ;_Setup1 = 2
- ;_Setup2 = 4
- ;_Setup3 = 6
- ;_Setup4 = 8
- ;_Setup5 = A
- ; Dynamic object variables
- obBNB_Routine = $38 ; .b
- obBNB_Draw = $39 ; .b
- obBNB_XPos = $3A ; .w
- obBNB_Count = $3C ; .b
- ; =============== S U B R O U T I N E =======================================
- Obj_NeoBahamut:
- move.l #Obj_Wait,address(a0)
- move.w #$4F,$2E(a0)
- move.l #Obj_NeoBahamut_Start,$34(a0)
- bset #0,render_flags(a0)
- rts
- ; ---------------------------------------------------------------------------
- Obj_NeoBahamut_Start:
- move.l #Obj_NeoBahamut_Main,address(a0)
- Obj_NeoBahamut_Main:
- moveq #0,d0
- move.b routine(a0),d0
- move.w NeoBahamut_Index(pc,d0.w),d0
- jsr NeoBahamut_Index(pc,d0.w)
- bsr.w BossNeoBahamut_CheckTouch
- bsr.w BossNeoBahamut_CheckFrame
- tst.b obBNB_Draw(a0)
- bne.w BossNeoBahamut_Return
- jmp (Draw_And_Touch_Sprite).l
- ; ---------------------------------------------------------------------------
- NeoBahamut_Index: offsetTable
- offsetTableEntry.w BossNeoBahamut_Init ; 0
- offsetTableEntry.w BossNeoBahamut_Setup ; 2
- offsetTableEntry.w BossNeoBahamut_Setup2 ; 4
- offsetTableEntry.w BossNeoBahamut_Setup3 ; 6
- offsetTableEntry.w BossNeoBahamut_Setup4 ; 8
- offsetTableEntry.w BossNeoBahamut_Setup5 ; A
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_Init:
- lea ObjDat3_BossNeoBahamut(pc),a1
- jsr (SetUp_ObjAttributes).l
- st (Boss_flag).w
- move.b #46/2,y_radius(a0)
- move.b #BossNeoBahamut_Hits,collision_property(a0)
- move.l #BossNeoBahamut_Intro,$34(a0)
- move.l #AniRaw_BossNeoBahamutPower,$30(a0)
- BossNeoBahamut_Return:
- rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_Setup3:
- bsr.w Obj_NeoBahamut_SendPos
- BossNeoBahamut_Setup:
- jsr (Animate_Raw).l
- jsr (MoveSprite2).l
- jmp (Obj_Wait).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_Setup2:
- jsr (Animate_Raw).l
- jsr (MoveSprite).l
- jmp (ObjHitFloor_DoRoutine).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_Setup4:
- move.b $40(a0),d0
- add.b d0,$3C(a0)
- btst #0,(Level_frame_counter+1).w
- beq.s +
- lea ChildObjDat_DEZRadiusSuperExplosion(pc),a2
- jsr (CreateChild6_Simple).l
- bne.s +
- move.b $3C(a0),$3C(a1)
- move.w #$380,priority(a1)
- + move.b (Level_frame_counter+1).w,d0
- andi.w #7,d0
- bne.s +
- sfx sfx_BreakBridge,0,0,0
- + bra.s BossNeoBahamut_Setup
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_Setup5:
- bsr.w Obj_NeoBahamut_Swing_UpAndDown_Slow
- bra.s BossNeoBahamut_Setup
- ; =============== S U B R O U T I N E =======================================
- BossNeoBahamut_Intro:
- sfx sfx_Flash,0,0,0
- move.b #$A,$40(a0)
- move.b #4,(Hyper_Sonic_flash_timer).w
- lea (Player_1).w,a1
- move.w #id_LookUp<<8,anim(a1)
- move.l #BossNeoBahamut_Return,$34(a0)
- lea ChildObjDat_BossNeoBahamut_Clone(pc),a2
- jmp (CreateChild1_Normal).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_Intro2:
- move.b #_Setup4,routine(a0)
- move.w #$7F,$2E(a0)
- move.l #BossNeoBahamut_Intro3,$34(a0)
- st (Screen_Shaking_Flag).w
- rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_Intro3:
- move.b #_Setup1,routine(a0)
- move.l #BossNeoBahamut_IntroJump,$34(a0)
- sf (Screen_Shaking_Flag).w
- rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_IntroJump:
- move.b #_Setup2,routine(a0)
- move.w #$280,x_vel(a0)
- move.w #-$400,y_vel(a0)
- move.l #BossNeoBahamut_IntroStop,$34(a0)
- rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_IntroStop:
- move.b #_Setup1,routine(a0)
- tst.b (Intro_flag).w
- bne.s BossNeoBahamut_IntroReturn
- st (Intro_flag).w
- move.l #BossNeoBahamut_Return,$34(a0)
- clr.l x_vel(a0)
- lea (Player_1).w,a1
- move.w #id_Wait2<<8,anim(a1)
- st (NoPause_flag).w
- lea AniRaw_BossNeoBahamutWait(pc),a1
- jsr (Set_Raw_Animation).l
- lea ChildObjDat_Dialog_Process(pc),a2
- jsr (CreateChild6_Simple).l
- bne.s +
- move.b #_NeoBahamutStart,routine(a1)
- move.l #DialogNeoBahamutStart_Process_Index-4,$34(a1)
- move.b #(DialogNeoBahamutStart_Process_Index_End-DialogNeoBahamutStart_Process_Index)/8,$39(a1)
- + rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_IntroReturn:
- move.l #BossNeoBahamut_SetSubroutine,$34(a0)
- clr.l x_vel(a0)
- lea AniRaw_BossNeoBahamutWait(pc),a1
- jsr (Set_Raw_Animation).l
- lea ChildObjDat_RobotnikHud(pc),a2
- jsr (CreateChild6_Simple).l
- bne.s +
- move.w a0,parent3(a1)
- + sf (Ctrl_1_locked).w
- jmp (Restore_PlayerControl).l
- ; =============== S U B R O U T I N E =======================================
- BossNeoBahamut_SetSubroutine:
- clearRAM3 Pos_objtable_Start, Pos_objtable_End
- moveq #0,d0
- move.b obBNB_Routine(a0),d0
- addq.b #1,obBNB_Routine(a0)
- lea BossNeoBahamut_SetMovement(pc),a1
- cmpi.b #BossNeoBahamut_Hits-3,$29(a0)
- bhs.s +
- lea BossNeoBahamut_SetMovement2(pc),a1
- + cmpi.b #BossNeoBahamut_Hits/3+1,$29(a0)
- bhs.s +
- lea BossNeoBahamut_SetMovement3(pc),a1
- + move.b (a1,d0.w),d0
- bmi.s +
- move.l BossNeoBahamut_Movement(pc,d0.w),$34(a0)
- rts
- + clr.b obBNB_Routine(a0)
- rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_SetMovement:
- dc.b 0<<2
- dc.b 1<<2
- dc.b 0<<2
- dc.b 2<<2
- dc.b 0<<2
- dc.b 1<<2
- dc.b 0<<2
- dc.b 1<<2
- dc.b 0<<2
- dc.b 3<<2
- dc.b 0<<2
- dc.b 1<<2
- dc.b 0<<2
- dc.b 3<<2
- dc.b 0<<2
- dc.b 2<<2
- dc.b -1 ; Конец
- even
- BossNeoBahamut_SetMovement2:
- dc.b 1<<2
- dc.b 0<<2
- dc.b 2<<2
- dc.b 1<<2
- dc.b 1<<2
- dc.b 0<<2
- dc.b 3<<2
- dc.b 1<<2
- dc.b 1<<2
- dc.b 0<<2
- dc.b 2<<2
- dc.b -1 ; Конец
- even
- BossNeoBahamut_SetMovement3:
- dc.b 1<<2
- dc.b 2<<2
- dc.b 1<<2
- dc.b 1<<2
- dc.b 3<<2
- dc.b 1<<2
- dc.b 3<<2
- dc.b 2<<2
- dc.b -1 ; Конец
- even
- BossNeoBahamut_Movement:
- dc.l BossNeoBahamut_WaitAttack ; 0
- dc.l BossNeoBahamut_SuperDashAttack ; 1
- dc.l BossNeoBahamut_ShotBallAttack ; 2
- dc.l BossNeoBahamut_SuperShotBallAttack ; 3
- ; ---------------------------------------------------------------------------
- ; Босс ожидает
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossNeoBahamut_WaitAttack:
- move.b #_Setup1,routine(a0)
- move.w #$4F,$2E(a0)
- move.l #BossNeoBahamut_SetSubroutine,$34(a0)
- lea AniRaw_BossNeoBahamutWait(pc),a1
- jmp (Set_Raw_Animation).l
- ; ---------------------------------------------------------------------------
- ; Босс атакует с помощью рывка
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossNeoBahamut_SuperDashAttack:
- move.b #_Setup3,routine(a0)
- sfx sfx_Signal,0,0,0
- move.l #BossNeoBahamut_Return,$34(a0)
- lea ChildObjDat_BossNeoBahamut_Timer(pc),a2
- jsr (CreateChild1_Normal).l
- lea AniRaw_BossNeoBahamutDashWait(pc),a1
- jmp (Set_Raw_Animation).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_SuperDashAttack_Start:
- sfx sfx_Boom,0,0,0
- move.w #-$C00,x_vel(a0)
- btst #0,render_flags(a0)
- bne.s +
- neg.w x_vel(a0)
- + move.l #BossNeoBahamut_SuperDashAttack_Check,$34(a0)
- lea ChildObjDat_BossNeoBahamut_Trail(pc),a2
- jsr (CreateChild6_Simple).l
- lea AniRaw_BossNeoBahamutDashAttack(pc),a1
- jmp (Set_Raw_Animation).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_SuperDashAttack_Check:
- move.w (Camera_X_pos).w,d0
- btst #0,render_flags(a0)
- bne.s +
- addi.w #$120,d0
- cmp.w x_pos(a0),d0
- bge.s +++
- bra.s ++
- + addi.w #$20,d0
- cmp.w x_pos(a0),d0
- ble.s ++
- + move.w #$F,$2E(a0)
- move.l #BossNeoBahamut_SuperDashAttack_Stop,$34(a0)
- clr.w x_vel(a0)
- + rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_SuperDashAttack_Stop:
- move.l #BossNeoBahamut_SuperDashAttack_ChangePos,$34(a0)
- lea AniRaw_BossNeoBahamutWait(pc),a1
- jmp (Set_Raw_Animation).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_SuperDashAttack_ChangePos:
- move.l #BossNeoBahamut_SetSubroutine,$34(a0)
- bchg #0,render_flags(a0)
- rts
- ; ---------------------------------------------------------------------------
- ; Босс атакует с помощью выстрелов вниз
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossNeoBahamut_ShotBallAttack:
- move.b #_Setup1,routine(a0)
- move.w #$4F,$2E(a0)
- sfx sfx_Circular,0,0,0
- move.l #BossNeoBahamut_ShotBallAttack_Jump,$34(a0)
- lea AniRaw_BossNeoBahamutShotBallWait(pc),a1
- jmp (Set_Raw_Animation).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_ShotBallAttack_Jump:
- move.l #BossNeoBahamut_ShotBallAttack_CheckPos,$34(a0)
- move.w #-$300,y_vel(a0)
- lea AniRaw_BossNeoBahamutPower(pc),a1
- jmp (Set_Raw_Animation).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_ShotBallAttack_CheckPos:
- move.w (Camera_Y_pos).w,d0
- addi.w #$40,d0
- cmp.w y_pos(a0),d0
- blo.s +
- move.w #$1F,$2E(a0)
- move.l #BossNeoBahamut_ShotBallAttack_SetAttack,$34(a0)
- clr.w y_vel(a0)
- move.b #19,obBNB_Count(a0)
- + rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_ShotBallAttack_SetAttack:
- move.b #_Setup5,routine(a0)
- move.w (Player_1+x_pos).w,obBNB_XPos(a0)
- move.l #BossNeoBahamut_Return,$34(a0)
- lea ChildObjDat_NeoBahamut_ShotBall_Aim(pc),a2
- jsr (CreateChild6_Simple).l
- bne.s +
- move.w obBNB_XPos(a0),$38(a1)
- + rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_ShotBallAttack_SetAnim:
- move.b #4,(Hyper_Sonic_flash_timer).w
- move.l #BossNeoBahamut_ShotBallAttack_Attack,$34(a0)
- lea AniRaw_BossNeoBahamutShotBallAttack(pc),a1
- jmp (Set_Raw_Animation).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_ShotBallAttack_Attack:
- move.w #7,$2E(a0)
- lea ChildObjDat_BossNeoBahamut_ShotBall(pc),a2
- jsr (CreateChild6_Simple).l
- bne.s +
- move.w obBNB_XPos(a0),$38(a1)
- + subq.b #1,obBNB_Count(a0)
- bne.s BossNeoBahamut_ShotBallAttack_Attack_Return
- move.l #BossNeoBahamut_ShotBallAttack_Attack_Fall,$34(a0)
- move.w #$1F,$2E(a0)
- lea AniRaw_BossNeoBahamutShotBallAttack2(pc),a1
- jsr (Set_Raw_Animation).l
- BossNeoBahamut_ShotBallAttack_Attack_Return:
- rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_ShotBallAttack_Attack_Fall:
- move.b #_Setup2,routine(a0)
- move.l #BossNeoBahamut_ShotBallAttack_Attack_FallReturn,$34(a0)
- lea AniRaw_BossNeoBahamutPower(pc),a1
- jmp (Set_Raw_Animation).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_ShotBallAttack_Attack_FallReturn:
- move.b #_Setup1,routine(a0)
- clr.w y_vel(a0)
- move.l #BossNeoBahamut_SuperDashAttack_ChangePos,$34(a0)
- bchg #0,render_flags(a0)
- lea AniRaw_BossNeoBahamutWait(pc),a1
- jmp (Set_Raw_Animation).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_ShotBallAttack_Attack_ChangePos:
- move.l #BossNeoBahamut_SetSubroutine,$34(a0)
- rts
- ; ---------------------------------------------------------------------------
- ; Босс атакует с помощью выстрелов шарами
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossNeoBahamut_SuperShotBallAttack:
- move.b #_Setup1,routine(a0)
- move.w #$1F,$2E(a0)
- move.b #4,obBNB_Count(a0)
- move.b #4,(Hyper_Sonic_flash_timer).w
- move.l #BossNeoBahamut_SuperShotBallAttack_Start,$34(a0)
- lea AniRaw_BossNeoBahamutAttack(pc),a1
- jmp (Set_Raw_Animation).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_SuperShotBallAttack_Start:
- move.w #$2F,$2E(a0)
- move.l #BossNeoBahamut_SuperShotBallAttack_ChangeAnim,$34(a0)
- lea ChildObjDat_NeoBahamut_SuperShotBall(pc),a2
- jsr (CreateChild6_Simple).l
- lea AniRaw_BossNeoBahamutAttack2(pc),a1
- jsr (Set_Raw_Animation).l
- subq.b #1,obBNB_Count(a0)
- bne.s +
- move.l #BossNeoBahamut_SuperShotBallAttack_Stop,$34(a0)
- + rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_SuperShotBallAttack_ChangeAnim:
- move.w #$2F,$2E(a0)
- move.l #BossNeoBahamut_SuperShotBallAttack_Start,$34(a0)
- lea AniRaw_BossNeoBahamutAttack(pc),a1
- jmp (Set_Raw_Animation).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_SuperShotBallAttack_Stop:
- move.l #BossNeoBahamut_SuperShotBallAttack_ChangePos,$34(a0)
- lea AniRaw_BossNeoBahamutWait(pc),a1
- jmp (Set_Raw_Animation).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_SuperShotBallAttack_ChangePos:
- move.l #BossNeoBahamut_SetSubroutine,$34(a0)
- rts
- ; ---------------------------------------------------------------------------
- ; Проверка кадра для выбора коллизии
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossNeoBahamut_CheckFrame:
- btst #6,status(a0)
- bne.s +
- moveq #0,d0
- move.b mapping_frame(a0),d0
- move.b CheckFrameNeoBahamut_Index(pc,d0.w),collision_flags(a0)
- + rts
- ; ---------------------------------------------------------------------------
- CheckFrameNeoBahamut_Index:
- dc.b $21|$80 ; 0
- dc.b $21|$80 ; 1
- dc.b $21 ; 2
- dc.b $21 ; 3
- dc.b $21 ; 4
- dc.b $21 ; 5
- dc.b $21 ; 6
- dc.b $21 ; 7
- dc.b $21|$80 ; 8
- dc.b $21 ; 9
- dc.b $21 ; A
- dc.b $21 ; B
- dc.b $21 ; C
- dc.b $21 ; D
- dc.b $21 ; E
- dc.b $21 ; F
- dc.b $21|$80 ; 10
- dc.b $21|$80 ; 11
- dc.b $21 ; 12
- dc.b $21 ; 13
- ; ---------------------------------------------------------------------------
- ; Проверка урона
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- BossNeoBahamut_CheckTouch:
- tst.b collision_flags(a0)
- bne.s BossNeoBahamut_CheckTouch_Return
- tst.b collision_property(a0)
- beq.s BossNeoBahamut_CheckTouch_WaitExplosive
- tst.b $1C(a0)
- bne.s ++
- move.b #$40,$1C(a0)
- sfx sfx_HurtFire,0,0,0
- bset #6,status(a0)
- cmpi.b #BossNeoBahamut_Hits-4,$29(a0)
- beq.s +
- cmpi.b #BossNeoBahamut_Hits/3,$29(a0)
- bne.s ++
- + clr.b obBNB_Routine(a0)
- + btst #0,$1C(a0)
- bne.s +
- eori.w #$6000,art_tile(a0)
- + subq.b #1,$1C(a0)
- bne.s BossNeoBahamut_CheckTouch_Return
- bclr #6,status(a0)
- move.b collision_restore_flags(a0),collision_flags(a0)
- BossNeoBahamut_CheckTouch_Return:
- rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_CheckTouch_WaitExplosive:
- move.l #BossNeoBahamut_CheckTouch_JumpExplosive,address(a0)
- move.l #BossNeoBahamut_CheckTouch_WaitPlayerExplosive,$34(a0)
- bset #6,status(a0)
- bset #7,status(a0)
- clr.w $2E(a0)
- move.w #-$600,y_vel(a0)
- move.w #-$280,x_vel(a0)
- btst #0,render_flags(a0)
- bne.s +
- neg.w x_vel(a0)
- + lea AniRaw_BossNeoBahamutPower(pc),a1
- jsr (Set_Raw_Animation).l
- jmp (BossDefeated_NoTime).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_CheckTouch_JumpExplosive:
- jsr (Animate_Raw).l
- jsr (MoveSprite).l
- jsr (ObjHitFloor_DoRoutine).l
- jmp (Draw_Sprite).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_CheckTouch_WaitPlayerExplosive:
- move.l #BossNeoBahamut_CheckTouch_DeathExplosive,address(a0)
- move.l #BossNeoBahamut_CheckTouch_DialogExplosive,$34(a0)
- clr.l x_vel(a0)
- lea AniRaw_BossNeoBahamutEnd(pc),a1
- jsr (Set_Raw_Animation).l
- BossNeoBahamut_CheckTouch_DeathExplosive:
- jsr (Animate_Raw).l
- jsr (Obj_Wait).l
- jmp (Draw_Sprite).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_CheckTouch_DialogExplosive:
- lea (Player_1).w,a1
- btst #Status_InAir,status(a1)
- bne.s BossNeoBahamut_CheckTouch_DialogExplosive_Return
- clr.w (Ctrl_1_logical).w
- jsr (Find_SonicTails).l
- move.b #$81,object_control(a1)
- move.w #id_LookUp<<8,anim(a1)
- jsr (Stop_Object).l
- bclr #Status_Facing,status(a1)
- tst.w d0
- beq.s +
- bset #Status_Facing,status(a1)
- + move.l #BossNeoBahamut_CheckTouch_DialogExplosive_Return,$34(a0)
- st (NoPause_flag).w
- lea ChildObjDat_Dialog_Process(pc),a2
- jsr (CreateChild6_Simple).l
- bne.s BossNeoBahamut_CheckTouch_DialogExplosive_Return
- move.b #_NeoBahamutEnd,routine(a1)
- move.l #DialogNeoBahamutEnd_Process_Index-4,$34(a1)
- move.b #(DialogNeoBahamutEnd_Process_Index_End-DialogNeoBahamutEnd_Process_Index)/8,$39(a1)
- BossNeoBahamut_CheckTouch_DialogExplosive_Return:
- rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_CheckTouch_Remove:
- move.w #$4F,$2E(a0)
- move.l #BossNeoBahamut_CheckTouch_Remove_SuperExplosion,address(a0)
- move.l #BossNeoBahamut_CheckTouch_Remove_End,$34(a0)
- BossNeoBahamut_CheckTouch_Remove_SuperExplosion:
- move.b $40(a0),d0
- add.b d0,$3C(a0)
- btst #0,(Level_frame_counter+1).w
- beq.s +
- lea ChildObjDat_DEZRadiusSuperExplosion(pc),a2
- jsr (CreateChild6_Simple).l
- bne.s +
- move.b $3C(a0),$3C(a1)
- move.w #$180,priority(a1)
- + move.b (Level_frame_counter+1).w,d0
- andi.w #7,d0
- bne.s +
- sfx sfx_BreakBridge,0,0,0
- + jsr (Obj_Wait).l
- jmp (Draw_Sprite).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_CheckTouch_Remove_End:
- addq.b #2,(Dynamic_resize_routine).w
- move.l #Go_Delete_Sprite,address(a0)
- rts
- ; ---------------------------------------------------------------------------
- ; Клон (Интро)
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_BossNeoBahamut_Clone:
- lea ObjDat3_BossNeoBahamut_Clone(pc),a1
- jsr (SetUp_ObjAttributes3).l
- bset #0,render_flags(a0)
- move.b #4,$40(a0)
- move.l #BossNeoBahamut_Clone_Frame2,address(a0)
- tst.b subtype(a0)
- beq.s BossNeoBahamut_Clone_Frame2
- neg.b $40(a0)
- move.l #BossNeoBahamut_Clone_Frame1,address(a0)
- BossNeoBahamut_Clone_Frame1:
- btst #0,(Level_frame_counter+1).w
- beq.s BossNeoBahamut_Clone_Draw
- BossNeoBahamut_Clone_Return:
- rts
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_Clone_Frame2:
- btst #0,(Level_frame_counter+1).w
- beq.s BossNeoBahamut_Clone_Return
- BossNeoBahamut_Clone_Draw:
- jsr (Refresh_ChildPosition).l
- move.b $40(a0),d0
- add.b d0,child_dx(a0)
- beq.s BossNeoBahamut_Clone_Remove
- jmp (Child_Draw_Sprite).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_Clone_Remove:
- move.l #Go_Delete_Sprite,address(a0)
- tst.b subtype(a0)
- bne.s BossNeoBahamut_Clone_Return2
- movea.w parent3(a0),a1
- move.l #BossNeoBahamut_Intro2,$34(a1)
- sf obBNB_Draw(a1)
- BossNeoBahamut_Clone_Return2:
- rts
- ; ---------------------------------------------------------------------------
- ; Таймер
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_BossNeoBahamut_Timer:
- lea ObjDat3_BossNeoBahamut_Timer(pc),a1
- jsr (SetUp_ObjAttributes).l
- move.l #BossNeoBahamut_Timer_Remove,$34(a0)
- move.l #BossNeoBahamut_Timer_Draw,address(a0)
- movea.w parent3(a0),a1
- move.l #AniRaw_BossNeoBahamut_Timer,d0
- cmpi.b #BossNeoBahamut_Hits-3,$29(a1)
- bhs.s +
- move.l #AniRaw_BossNeoBahamut_Timer2,d0
- + cmpi.b #BossNeoBahamut_Hits/3+1,$29(a1)
- bhs.s +
- move.l #AniRaw_BossNeoBahamut_Timer3,d0
- + move.l d0,$30(a0)
- BossNeoBahamut_Timer_Draw:
- jsr (Animate_Raw).l
- jmp (Child_Draw_Sprite).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_Timer_Remove:
- move.b #4,(Hyper_Sonic_flash_timer).w
- move.l #Go_Delete_Sprite,address(a0)
- movea.w parent3(a0),a1
- move.l #BossNeoBahamut_SuperDashAttack_Start,$34(a1)
- rts
- ; ---------------------------------------------------------------------------
- AniRaw_BossNeoBahamut_Timer:
- dc.b $28, 0, 0, 1, 2, $F4
- AniRaw_BossNeoBahamut_Timer2:
- dc.b $28, 1, 1, 2, $F4, 0
- AniRaw_BossNeoBahamut_Timer3:
- dc.b $28, 2, 2, $F4
- ; ---------------------------------------------------------------------------
- ; Тень босса
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_BossNeoBahamut_Trail:
- moveq #0,d0
- move.b subtype(a0),d0
- lsl.b #3,d0
- addi.b #16,d0
- move.b d0,subtype(a0)
- movea.w parent3(a0),a1
- bset #0,render_flags(a0)
- btst #0,render_flags(a1)
- bne.s +
- bclr #0,render_flags(a0)
- + lea ObjDat3_BossNeoBahamut_Trail(pc),a1
- jsr (SetUp_ObjAttributes3).l
- move.l #+,address(a0)
- move.l #AniRaw_BossNeoBahamutDashAttack,$30(a0)
- + bsr.w Obj_NeoBahamut_CopyPos
- bsr.s BossNeoBahamut_Trail_Remove
- jsr (Animate_Raw).l
- jmp (Child_DrawTouch_Sprite).l
- ; ---------------------------------------------------------------------------
- BossNeoBahamut_Trail_Remove:
- movea.w parent3(a0),a1
- cmpi.l #AniRaw_BossNeoBahamutDashAttack,$30(a1)
- beq.s +
- move.l #Go_Delete_Sprite,address(a0)
- + rts
- ; ---------------------------------------------------------------------------
- ; Прицел перед выстрелом
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_NeoBahamut_ShotBall_Aim:
- move.w $38(a0),x_pos(a0)
- move.w (Camera_Y_pos).w,d0
- add.w #$C8,d0
- move.w d0,y_pos(a0)
- sfx sfx_Squeak,0,0,0
- lea ObjDat3_NeoBahamut_ShotBall_Aim(pc),a1
- jsr (SetUp_ObjAttributes).l
- move.w #$7F,$2E(a0)
- move.l #+,address(a0)
- move.l #NeoBahamut_ShotBall_Aim_Remove,$34(a0)
- move.l #AniRaw_NeoBahamut_ShotBall_Aim,$30(a0)
- + jsr (Animate_Raw).l
- jsr (Obj_Wait).l
- jmp (Child_Draw_Sprite).l
- ; ---------------------------------------------------------------------------
- NeoBahamut_ShotBall_Aim_Remove:
- movea.w parent3(a0),a1
- move.l #BossNeoBahamut_ShotBallAttack_SetAnim,$34(a1)
- move.l #Go_Delete_Sprite,address(a0)
- rts
- ; ---------------------------------------------------------------------------
- AniRaw_NeoBahamut_ShotBall_Aim:
- dc.b 0, 0, 1, $FC
- ; ---------------------------------------------------------------------------
- ; Шар для выстрела
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_NeoBahamut_ShotBall:
- move.w $38(a0),d1
- move.w (Camera_Y_pos).w,d2
- add.w #$C8,d2
- sub.w x_pos(a0),d1
- sub.w y_pos(a0),d2
- jsr (GetArcTan).l
- jsr (GetSineCosine).l
- move.w #$C00,d2
- muls.w d2,d1
- asr.l #8,d1
- move.w d1,x_vel(a0)
- muls.w d2,d0
- asr.l #8,d0
- move.w d0,y_vel(a0)
- lea ObjDat3_BossNeoBahamut_ShotBall(pc),a1
- jsr (SetUp_ObjAttributes).l
- move.l #NeoBahamut_ShotBall_Remove,$34(a0)
- move.l #NeoBahamut_ShotBall_Draw,address(a0)
- move.l #AniRaw_NeoBahamut_ShotBall,$30(a0)
- NeoBahamut_ShotBall_Draw:
- jsr (Animate_Raw).l
- jsr (MoveSprite2).l
- jsr (ObjHitFloor_DoRoutine).l
- jmp (Sprite_CheckDeleteTouchXY).l
- ; ---------------------------------------------------------------------------
- NeoBahamut_ShotBall_Remove:
- sfx sfx_BreakBridge,0,0,0
- move.w #4,(Screen_Shaking_Flag).w
- move.l #Go_Delete_Sprite,address(a0)
- lea ChildObjDat_NeoBahamut_ShotBall_Explosion(pc),a2
- jmp (CreateChild6_Simple).l
- ; ---------------------------------------------------------------------------
- AniRaw_NeoBahamut_ShotBall:
- dc.b 0, 1, 2, $FC
- ; ---------------------------------------------------------------------------
- ; Шар для выстрела (Взрывы)
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_NeoBahamut_ShotBall_Explosion:
- lea ObjDat3_BossNeoBahamut_ShotBall(pc),a1
- jsr (SetUp_ObjAttributes).l
- clr.w x_vel(a0)
- move.w #-$200,y_vel(a0)
- move.l #NeoBahamut_ShotBall_Explosion_Anim,address(a0)
- jsr (Random_Number).l
- move.w d0,d1
- andi.w #$1F,d0
- addi.w #$10,d0
- andi.w #1,d1
- bne.s +
- neg.w d0
- + add.w d0,x_pos(a0)
- NeoBahamut_ShotBall_Explosion_Anim:
- subq.b #1,anim_frame_timer(a0)
- bpl.s +
- move.b #3,anim_frame_timer(a0)
- addq.b #1,mapping_frame(a0)
- cmpi.b #8,mapping_frame(a0)
- beq.w NeoBahamut_ShotBall_Explosion_Remove
- + jsr (MoveSprite2).l
- jmp (Draw_Sprite).l
- ; ---------------------------------------------------------------------------
- NeoBahamut_ShotBall_Explosion_Remove:
- move.l #Go_Delete_Sprite,address(a0)
- rts
- ; ---------------------------------------------------------------------------
- ; Супер шар для выстрела
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_NeoBahamut_SuperShotBall:
- clearRAM3 Pos_objtable_Start, Pos_objtable_End
- lea (Player_1).w,a1
- move.w x_pos(a1),d1
- move.w y_pos(a1),d2
- sub.w x_pos(a0),d1
- sub.w y_pos(a0),d2
- jsr (GetArcTan).l
- jsr (GetSineCosine).l
- move.w #$800,d2
- muls.w d2,d1
- asr.l #8,d1
- move.w d1,x_vel(a0)
- muls.w d2,d0
- asr.l #8,d0
- move.w d0,y_vel(a0)
- sfx sfx_Laser,0,0,0
- move.w #4,(Screen_Shaking_Flag).w
- lea ObjDat3_BossNeoBahamut_SuperShotBall(pc),a1
- jsr (SetUp_ObjAttributes).l
- lea ChildObjDat_NeoBahamut_SuperShotBall_Trail(pc),a2
- jsr (CreateChild6_Simple).l
- move.l #NeoBahamut_SuperShotBall_Remove,$34(a0)
- move.l #NeoBahamut_SuperShotBall_Draw,address(a0)
- move.l #AniRaw_NeoBahamut_SuperShotBall,$30(a0)
- NeoBahamut_SuperShotBall_Draw:
- jsr (Animate_Raw).l
- jsr (MoveSprite2).l
- jsr (ObjHitFloor_DoRoutine).l
- bsr.w Obj_NeoBahamut_SendPos
- jmp (Sprite_CheckDeleteTouchXY).l
- ; ---------------------------------------------------------------------------
- NeoBahamut_SuperShotBall_Remove:
- sfx sfx_BreakBridge,0,0,0
- move.w #4,(Screen_Shaking_Flag).w
- move.l #Obj_DEZRadiusExplosion,address(a0)
- bset #7,status(a0)
- rts
- ; ---------------------------------------------------------------------------
- AniRaw_NeoBahamut_SuperShotBall:
- dc.b 1, 1, 2, 1, 5, $FC
- ; ---------------------------------------------------------------------------
- ; Супер шар для выстрела (Тень)
- ; ---------------------------------------------------------------------------
- ; =============== S U B R O U T I N E =======================================
- Obj_NeoBahamut_SuperShotBall_Trail:
- moveq #0,d0
- move.b subtype(a0),d0
- lsl.b #3,d0
- addi.b #$14,d0
- move.b d0,subtype(a0)
- lea ObjDat3_BossNeoBahamut_SuperShotBall_Trail(pc),a1
- jsr (SetUp_ObjAttributes).l
- move.l #NeoBahamut_SuperShotBall_Trail_Draw,address(a0)
- NeoBahamut_SuperShotBall_Trail_Draw:
- bsr.w Obj_NeoBahamut_CopyPos
- jmp (Child_DrawTouch_Sprite).l
- ; =============== S U B R O U T I N E =======================================
- Obj_NeoBahamut_Swing_UpAndDown_Slow:
- moveq #0,d0
- move.b angle(a0),d0
- addq.b #6,d0
- move.b d0,angle(a0)
- jsr (GetSineCosine).l
- asr.w #2,d0
- move.w d0,y_vel(a0)
- rts
- ; =============== S U B R O U T I N E =======================================
- Obj_NeoBahamut_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_NeoBahamut_CopyPos:
- move.w (Pos_objTable_index).w,d0
- lea (Pos_objTable).w,a1
- sub.b subtype(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 =======================================
- ObjDat3_BossNeoBahamut:
- dc.l Map_NeoBahamut
- dc.w $60E0
- dc.w $200
- dc.b 64/2
- dc.b 64/2
- dc.b 0
- dc.b $F
- ObjDat3_BossNeoBahamut_Clone:
- dc.w $200
- dc.b 64/2
- dc.b 64/2
- dc.b 0
- dc.b 0
- ObjDat3_BossNeoBahamut_Trail:
- dc.w $280
- dc.b 64/2
- dc.b 64/2
- dc.b 8
- dc.b 0
- ObjDat3_BossNeoBahamut_Timer:
- dc.l Map_NeoBahamutTimer
- dc.w $62F6
- dc.w $200
- dc.b 16/2
- dc.b 16/2
- dc.b 0
- dc.b 0
- ObjDat3_BossNeoBahamut_ShotBall:
- dc.l Map_NeoBahamutShotBall
- dc.w $6300
- dc.w $200
- dc.b 16/2
- dc.b 16/2
- dc.b 1
- dc.b $B|$80
- ObjDat3_NeoBahamut_ShotBall_Aim:
- dc.l Map_BossAim
- dc.w $E3A0
- dc.w 0
- dc.b 44/2
- dc.b 44/2
- dc.b 0
- dc.b 0
- ObjDat3_BossNeoBahamut_SuperShotBall:
- dc.l Map_BossBall
- dc.w $360
- dc.w $180
- dc.b 16/2
- dc.b 16/2
- dc.b 1
- dc.b $B|$80
- ObjDat3_BossNeoBahamut_SuperShotBall_Trail:
- dc.l Map_BossBall
- dc.w $360
- dc.w $180
- dc.b 8/2
- dc.b 8/2
- dc.b 0
- dc.b $18|$80
- ChildObjDat_BossNeoBahamut_Clone:
- dc.w 2-1
- dc.l Obj_BossNeoBahamut_Clone
- dc.b -64, 0
- dc.l Obj_BossNeoBahamut_Clone
- dc.b 64, 0
- ChildObjDat_BossNeoBahamut_Timer:
- dc.w 1-1
- dc.l Obj_BossNeoBahamut_Timer
- dc.b 0, -32
- ChildObjDat_BossNeoBahamut_Trail:
- dc.w 4-1
- dc.l Obj_BossNeoBahamut_Trail
- ChildObjDat_BossNeoBahamut_ShotBall:
- dc.w 1-1
- dc.l Obj_NeoBahamut_ShotBall
- ChildObjDat_NeoBahamut_ShotBall_Aim:
- dc.w 1-1
- dc.l Obj_NeoBahamut_ShotBall_Aim
- ChildObjDat_NeoBahamut_ShotBall_Explosion:
- dc.w 2-1
- dc.l Obj_NeoBahamut_ShotBall_Explosion
- ChildObjDat_NeoBahamut_SuperShotBall:
- dc.w 1-1
- dc.l Obj_NeoBahamut_SuperShotBall
- ChildObjDat_NeoBahamut_SuperShotBall_Trail:
- dc.w 4-1
- dc.l Obj_NeoBahamut_SuperShotBall_Trail
- AniRaw_BossNeoBahamutPower:
- dc.b 1, 0, 1, $FC
- AniRaw_BossNeoBahamutAttack:
- dc.b 1, 2, 3, $FC
- AniRaw_BossNeoBahamutAttack2:
- dc.b 1, 4, 5, $FC
- AniRaw_BossNeoBahamutDashWait:
- dc.b 1, 6, 7, $FC
- AniRaw_BossNeoBahamutDashAttack:
- dc.b 7, 8, $FC, 0
- AniRaw_BossNeoBahamutWait:
- dc.b 6, 9, $A, $FC
- AniRaw_BossNeoBahamutShotBallWait:
- dc.b 6, $B, $C, $D, $E, $F, $FC, 0
- AniRaw_BossNeoBahamutShotBallAttack:
- dc.b 6, $10, $11, $FC
- AniRaw_BossNeoBahamutShotBallAttack2:
- dc.b 7, $11, $FC, 0
- AniRaw_BossNeoBahamutEnd:
- dc.b $F, $12, $13, $FC
- ; ---------------------------------------------------------------------------
- include "Objects/Boss Neo Bahamut/Object Data/Map - Neo Bahamut.asm"
- include "Objects/Boss Neo Bahamut/Object Data/Map - Explosion.asm"
- include "Objects/Boss Neo Bahamut/Object Data/Map - Number.asm"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement