123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870 |
- ************************************************************************
- * *
- * 044 [ART OF FIGHT] *
- * HERO PWORK PROGRAM *
- * by S.OKADA from 92/02/07 Fri 13:46 *
- * *
- ************************************************************************
- XDEF PM_HERO,PM_HERO_HEAD,PM_HERO_ATTACK,PM_HERO_AREA
- XDEF PM_HERO_BODY,PM_HERO_SHADOW,PM_HERO_WEAK
- XDEF PM_STAR,PM_SP2,PM_SP3
- XDEF DEAD_NEXT
- XDEF PWORK_HIT
- XDEF TAMA_SET,MEGANE
- XDEF KAGE_CHG,BLOD_SET,GETA_MAKE,PM_GETA,PM_DESI
- XDEF STAR_MAKE
- XDEF SPIRIT_RANK
- XREF ?A5
- ;by HERO
- XREF Z_MINIMUM
- ;by GAME_SUB
- XREF FREE_OBJ_WORK,FREE_HERO_PWORK,SET_HIT_AREA,SET_HIT_AREA_HERO
- ;by ACT_SUB
- XREF REDUCTION_MOVE
- ;by SOUND
- XREF SET_SOUND
- ;by ACTION
- XREF NEXT_ACTION,SORT_SET,ACTION_SET
- ;by SUB
- XREF PWORK_SET
- SECT HERO,,C
- INCLUDE MACRO.INC
- INCLUDE NEO_GEO.INC
- INCLUDE LABEL.INC
- INCLUDE ACT_No.INC
- INCLUDE HFLAG.INC
- INCLUDE SMACRO.INC
- INCLUDE SCODE.INC
- PWORK_HIT:
- MOVE.B WORK_N0(A6),(A5)
- MOVE.W (A5),D0
- LEA.L 0(A5,D0.W),A4
- MOVEP.W WORK_N0(A4),D0
- CLR.B D0
- LEA.L 0(A5,D0.W),A3
- TST.B HIT_FLAG(A3)
- BPL.S PWORK_HIT_3
- BSET.B #0,WEAK_HIT(A6)
- PWORK_HIT_3:
- BSR DAMAGE_SET weak point
- MOVEP.W WORK_N2(A4),D0
- CLR.B D0
- LEA.L 0(A5,D0.W),A3
- BSR DAMAGE_SET body1
- MOVEP.W WORK_N3(A4),D0
- CLR.B D0
- LEA.L 0(A5,D0.W),A3
- BSR DAMAGE_SET body2
- MOVEP.W WORK_N1(A4),D0
- CLR.B D0
- LEA.L 0(A5,D0.W),A3
- TST.B HIT_FLAG(A3)
- BPL.S PWORK_HIT_1
- TST.B HIT_FLAG(A4)
- BMI.S PWORK_HIT_1
- CMP.W #2,ACT_No(A3)
- BCC.S PWORK_HIT_1
- ADDQ.W #1,ACT_No(A3)
- PWORK_HIT_1:
- BSR DAMAGE_SET head
- LEA.L (A4),A3
- BSR DAMAGE_SET p_main gard
- BTST.B #BHF_DAMAGE,FLAG(A6)
- BNE DAMAGE_SET_SUB
- RTS
- DAMAGE_SET:
- BCLR.B #0,HIT_FLAG(A3)
- BTST.B #0,HIT_OFF(A6)
- BNE.S DAMAGE_SET_1
- BSET.B #0,HIT_FLAG(A3)
- DAMAGE_SET_1:
- TST.B HIT_FLAG(A3)
- BPL DAMAGE_SET_6
- OR.B #HF_DAMAGE,FLAG(A6)
- MOVEP.W HIT_PLAYER(A3),D4
- CLR.B D4
- MOVE.W D4,DEF_HIT_PLAYER(A6)
- MOVE.B LEVEL(A5,D4.W),DAMAGE_LEVEL(A6)
- MOVE.B HIT_TYPE_No(A5,D4.W),D0
- OR.B HIT_TYPE_No(A3),D0
- MOVE.B D0,DEF_HIT_TYPE_No(A6)
- RTS
- DAMAGE_SET_SUB:
- MOVE.W DEF_HIT_PLAYER(A6),D4
- BSR ATTACK_PARM_SET
- MOVEP.W WORK_N0(A4),D0
- CLR.B D0
- MOVE.B WORK_N1(A5,D0.W),(A5)
- MOVE.W (A5),D0
- LEA.L 0(A5,D0.W),A0
- MOVE.W HIT_LEFT(A0),D0
- CMP.W HIT_LEFT(A5,D4.W),D0
- BGE.S DAMAGE_SET_2
- MOVE.W HIT_LEFT(A5,D4.W),D0
- DAMAGE_SET_2:
- MOVE.W HIT_RIGHT(A0),D1
- CMP.W HIT_RIGHT(A5,D4.W),D1
- BLE.S DAMAGE_SET_3
- MOVE.W HIT_RIGHT(A5,D4.W),D1
- DAMAGE_SET_3:
- ADD.W D0,D1
- ASR.W #1,D1
- MOVE.W D1,TARGET_X(A6)
- MOVE.W HIT_LOWER(A0),D0
- CMP.W HIT_LOWER(A5,D4.W),D0
- BGE.S DAMAGE_SET_4
- MOVE.W HIT_LOWER(A5,D4.W),D0
- DAMAGE_SET_4:
- MOVE.W HIT_UPPER(A0),D1
- CMP.W HIT_UPPER(A5,D4.W),D1
- BLE.S DAMAGE_SET_5
- MOVE.W HIT_UPPER(A5,D4.W),D1
- DAMAGE_SET_5:
- ADD.W D0,D1
- ASR.W #1,D1
- MOVE.W D1,TARGET_Y(A6)
- CLR.B HIT_FLAG(A4)
- MOVEP.W WORK_N0(A4),D0
- CLR.B D0
- CLR.B HIT_FLAG(A5,D0.W)
- MOVEP.W WORK_N1(A4),D0
- CLR.B D0
- CLR.B HIT_FLAG(A5,D0.W)
- MOVEP.W WORK_N2(A4),D0
- CLR.B D0
- CLR.B HIT_FLAG(A5,D0.W)
- MOVEP.W WORK_N3(A4),D0
- CLR.B D0
- CLR.B HIT_FLAG(A5,D0.W)
- DAMAGE_SET_6:
- RTS
- ATTACK_PARM_SET:
- TST.B DEF_HIT_TYPE_No(A6)
- BMI APS_TAMA
- MOVE.L ANOTHER_PLAYER(A6),A0
- MOVE.B GARD_LEVEL(A0),DEF_GARD_LEVEL(A6)
- MOVE.B HIT_STOP(A0),DEF_HIT_STOP(A6)
- MOVE.B HIT_LR(A0),DEF_HIT_LR(A6)
- MOVE.B DAMAGE_ACT_TYPE(A0),DEF_DAMAGE_ACT_TYPE(A6)
- MOVE.L HIT_SCORE(A0),DEF_HIT_SCORE(A6)
- RTS
- APS_TAMA:
- MOVE.B 79H(A5,D4.W),DEF_GARD_LEVEL(A6)
- MOVE.B 7BH(A5,D4.W),DEF_HIT_STOP(A6)
- MOVE.B 7CH(A5,D4.W),DEF_HIT_LR(A6)
- MOVE.B 7DH(A5,D4.W),DEF_DAMAGE_ACT_TYPE(A6)
- MOVE.L LIFE(A5,D4.W),DEF_HIT_SCORE(A6)
- RTS
- STAR_MAKE:
- MOVE.L #P_STAR*10000H,D2
- MOVE.W #C_HITG,D2
- MOVEQ.L #0FH,D1
- AND.B DEF_HIT_TYPE_No(A6),D1
- CMP.B #3,D1 gard ?
- BEQ.S STAR_MAKE_1
- MOVE.W #C_HITS,D2
- CMP.B #16,D0
- BCS.S STAR_MAKE_1
- MOVE.W #C_HITL,D2
- STAR_MAKE_1:
- JSR.S FREE_OBJ_WORK
- BEQ STAR_MAKE_9
- MOVE.B WORK_No(A0),HIT_WORK_No(A6)
- MOVE.W TARGET_X(A6),D3
- MOVE.W Y_POSITION(A6),D4
- MOVE.B #0B8H,D5
- JSR.S PWORK_SET
- MOVE.W TARGET_Y(A6),Z_POSITION(A0)
- STAR_MAKE_9:
- RTS
- PM_HERO:
- MOVE.B MASTER_No(A6),(A5)
- MOVE.W (A5),D0
- LEA.L -LOG(A5,D0.W),A3
- BTST.B #BHF_NON_ACT,FLAG(A3)
- BNE PM_HERO_1
- TST.B MASTER_REQUEST(A6)
- BEQ.S PM_HERO_1
- BMI.S PM_HERO_101
- JSR ALL_HIT_CLEAR(PC)
- PM_HERO_101:
- CLR.B MASTER_REQUEST(A6)
- MOVE.W HERO_ACT_No(A3),D0
- JSR.S ACTION_SET
- PM_HERO_1:
- MOVE.L X_POSITION(A6),D0
- ADD.L VX(A6),D0
- MOVE.L D0,X_POSITION(A6)
- MOVE.L D0,X_POSITION(A3)
- MOVE.L Y_POSITION(A6),D0
- ADD.L VY(A6),D0
- MOVE.L D0,Y_POSITION(A6)
- MOVE.L D0,Y_POSITION(A3)
- MOVE.L Z_POSITION(A6),D0
- ADD.L VZ(A6),D0
- MOVE.L D0,Z_POSITION(A6)
- MOVE.L D0,Z_POSITION(A3)
- JSR.S REDUCTION_MOVE
- BCLR.B #BHF_NON_ACT,FLAG(A3)
- BNE.S PM_HERO_2
- JSR.S NEXT_ACTION
- TST.W ACT_No(A6)
- BPL.S PM_HERO_2
- TST.B ACT_FLAG(A6)
- BPL.S PM_HERO_2
- MOVE.L ADRS1(A6),A0
- MOVE.W (A0)+,ACT_No(A6)
- MOVE.L A0,ADRS1(A6)
- BCLR.B #7,ACT_FLAG(A6)
- MOVE.B #-1,ACT_COUNT(A6)
- MOVE.W ACT_No(A6),ADC_ACT_No(A3)
- MOVE.B ACT_COUNT(A6),ADC_ACT_COUNT(A3)
- PM_HERO_2:
- MOVEQ.L #00000111B,D0
- AND.B ACT_FLAG(A6),D0
- ADD.B D0,D0
- SUB.B PLAYER_No+1+PLAYER_OFFSET(A3),D0
- ADD.B #91H,D0
- MOVE.B D0,PRIORITY(A6)
- JSR.S SET_HIT_AREA_HERO
- PM_HERO_21:
- MOVE.W X_POSITION(A6),D0
- MOVE.W D0,D1
- SUB.W BACK2+Wx(A5),D0
- BLT.S PM_HERO_3
- SUB.W BACK2+WxRIGHT(A5),D1
- BGT.S PM_HERO_3
- BCLR.B #ACTAT_CUT,ACT_ATTR(A6)
- JSR.S SORT_SET
- RTS
- PM_HERO_3:
- BSET.B #ACTAT_CUT,ACT_ATTR(A6)
- JSR SORT_SET
- RTS
- DEAD_NEXT:
- MOVEP.W MASTER_No(A6),D0
- CLR.B D0
- TST.W HERO_LIFE-LOG(A5,D0.W)
- BEQ.S DEAD_NEXT_1
- MOVE.W (A0),ACT_No(A6)
- MOVE.B #-1,ACT_COUNT(A6)
- DEAD_NEXT_1:
- ADDQ.W #2,A0
- RTS
- ALL_HIT_CLEAR:
- CLR.L HIT_OFS_X(A6)
- MOVEP.W WORK_N0(A6),D0
- CLR.B D0
- CLR.L HIT_OFS_X(A5,D0.W)
- CLR.W ACT_No(A5,D0.W)
- MOVE.B WORK_N0(A5,D0.W),(A5)
- MOVE.W (A5),D0
- CLR.L HIT_OFS_X(A5,D0.W)
- CLR.L VX(A5,D0.W)
- CLR.L VY(A5,D0.W)
- MOVEP.W WORK_N1(A6),D0
- CLR.B D0
- CLR.L HIT_OFS_X(A5,D0.W)
- MOVEP.W WORK_N2(A6),D0
- CLR.B D0
- CLR.L HIT_OFS_X(A5,D0.W)
- MOVEP.W WORK_N3(A6),D0
- CLR.B D0
- CLR.L HIT_OFS_X(A5,D0.W)
- RTS
- PM_STAR:
- TST.B ACT_FLAG(A6)
- BPL.S PM_STAR_1
- CLR.W TYPE(A6)
- RTS
- PM_STAR_1:
- JSR.S REDUCTION_MOVE
- JSR.S NEXT_ACTION
- JSR.S SORT_SET
- RTS
- BLOD_SET:
- MOVE.L (A0)+,REG_D0(A5)
- MOVE.W (A0)+,REG_D1(A5)
- MOVEM.L A0/A6,-(SP)
- JSR.S FREE_OBJ_WORK
- BEQ BLOD_SET_END
- MOVE.W #P_STAR,D2
- SWAP D2
- MOVE.W REG_D1(A5),D2
- MOVE.W Y_POSITION(A6),D4
- MOVE.B #0B8H,D5
- JSR.S PWORK_SET
- MOVE.W REG_D0(A5),D1
- MOVEQ.L #1,D0
- AND.B ACT_ATTR(A6),D0
- BEQ.S BLOD_SET_1
- NEG.W D1
- BLOD_SET_1:
- OR.B D0,ACT_ATTR(A0)
- ADD.W X_POSITION(A6),D1
- MOVE.W D1,X_POSITION(A0)
- MOVE.W REG_D0+2(A5),D0
- ADD.W Z_POSITION(A6),D0
- MOVE.W D0,Z_POSITION(A0)
- BLOD_SET_END:
- MOVEM.L (SP)+,A0/A6
- RTS
- MEGANE:
- MOVEP.W WORK_N1(A6),D0
- CLR.B D0
- CMP.W #1,ACT_No(A5,D0.W)
- BEQ.S GETA_MAKE
- ADDQ.L #6,A0
- RTS
- GETA_MAKE:
- MOVE.L (A0)+,REG_D0(A5)
- MOVE.W (A0)+,REG_D1(A5)
- MOVEM.L A0/A6,-(SP)
- JSR.S FREE_OBJ_WORK
- BEQ GETA_SET_END
- MOVE.W #P_GETA,D2
- SWAP D2
- MOVE.W #C_GETA,D2
- MOVE.W Y_POSITION(A6),D4
- MOVE.B #0B8H,D5
- JSR.S PWORK_SET
- MOVE.W REG_D0(A5),D1
- MOVEQ.L #1,D0
- AND.B ACT_ATTR(A6),D0
- BEQ.S GETA_SET_1
- NEG.W D1
- GETA_SET_1:
- OR.B D0,ACT_ATTR(A0)
- ADD.W X_POSITION(A6),D1
- MOVE.W D1,X_POSITION(A0)
- MOVE.W REG_D0+2(A5),D0
- ADD.W Z_POSITION(A6),D0
- MOVE.W D0,Z_POSITION(A0)
- MOVE.W REG_D1(A5),D0
- ADD.W D0,D0
- ADD.W D0,D0
- ADD.W D0,D0
- MOVE.L GETA_DATA(PC,D0.W),VZ(A0)
- CLR.W VX+2(A0)
- MOVE.W GETA_DATA+4(PC,D0.W),VX(A0)
- MOVE.W GETA_DATA+6(PC,D0.W),ACT_No(A0)
- BTST.B #ACTAT_FLIP,ACT_ATTR(A0)
- BEQ.S GETA_SET_END
- NEG.W VX(A0)
- GETA_SET_END:
- MOVEM.L (SP)+,A0/A6
- RTS
- GETA_DATA:
- DC.L 08C000H
- DC.W -0006H,C_GETA
- DC.L 0BC000H
- DC.W -0004H,C_GETA
- DC.L 0BC000H
- DC.W -0003H,C_E4_HAT
- DC.L 040000H
- DC.W -0002H,C_E6_MEGANE
- DC.L 040000H
- DC.W -0002H,C_E7_MEGANE
- DC.L -20000H
- DC.W -0003H,C_E2_GUM
- PM_GETA:
- MOVE.W VX(A6),D0
- ADD.W D0,X_POSITION(A6)
- MOVE.L VZ(A6),D0
- SUB.L #9000H,D0
- MOVE.L D0,VZ(A6)
- ADD.L D0,Z_POSITION(A6)
- BMI.S GETA_END
- JSR.S REDUCTION_MOVE
- JSR.S NEXT_ACTION
- JSR.S SORT_SET
- RTS
- GETA_END:
- CLR.W TYPE(A6)
- RTS
- KAGE_CHG:
- MOVEP.W WORK_N3(A6),D0
- CLR.B D0
- MOVE.W #C_KAGE,ACT_No(A5,D0.W)
- MOVE.W (A0)+,D1
- MOVE.B D1,ACT_COUNT(A5,D0.W)
- MOVE.B #-1,ACT_TIMER(A5,D0.W)
- MOVE.B #1,ACT_DEC(A5,D0.W)
- RTS
- HERO_MASTER_GET:
- MOVE.B MASTER_No(A6),(A5)
- MOVE.W (A5),D0
- LEA.L 0(A5,D0.W),A4
- MOVE.B MASTER_No(A4),(A5)
- MOVE.W (A5),D0
- LEA.L -LOG(A5,D0.W),A3
- MOVE.L X_POSITION(A4),X_POSITION(A6)
- MOVE.L Y_POSITION(A4),Y_POSITION(A6)
- MOVE.L Z_POSITION(A4),Z_POSITION(A6)
- MOVE.W DISP_X(A4),DISP_X(A6)
- MOVE.W DISP_Y(A4),DISP_Y(A6)
- MOVE.B ACT_ATTR(A4),ACT_ATTR(A6)
- RTS
- PM_HERO_HEAD:
- JSR HERO_MASTER_GET(PC)
- JSR.S SET_HIT_AREA_HERO
- RTS
- PM_HERO_ATTACK:
- MOVE.B MASTER_No(A6),(A5)
- MOVE.W (A5),D0
- LEA.L 0(A5,D0.W),A4
- MOVE.B MASTER_No(A4),(A5)
- MOVE.W (A5),D0
- LEA.L -LOG(A5,D0.W),A3
- MOVE.L X_POSITION(A4),X_POSITION(A6)
- MOVE.L Y_POSITION(A4),Y_POSITION(A6)
- MOVE.L Z_POSITION(A4),Z_POSITION(A6)
- MOVE.W DISP_X(A4),DISP_X(A6)
- MOVE.W DISP_Y(A4),DISP_Y(A6)
- MOVE.B ACT_ATTR(A4),ACT_ATTR(A6)
- MOVE.L VX(A6),D0
- BTST.B #0,MAIN_COUNT+3(A5)
- BEQ.S PM_HERO_ATTACK_1
- MOVE.L VY(A6),D0
- PM_HERO_ATTACK_1:
- MOVE.L D0,HIT_OFS_X(A6)
- BEQ.S PM_HERO_OFF_1
- TST.B HIT_OFF(A3)
- BMI.S PM_HERO_OFF_1
- MOVE.B ATTACK_LEVEL(A3),LEVEL(A6)
- BSET.B #0,HIT_FLAG(A6)
- JSR.S SET_HIT_AREA
- RTS
- PM_HERO_OFF_1:
- MOVE.B #0,HIT_FLAG(A6)
- JSR.S SET_HIT_AREA
- RTS
- PM_HERO_AREA:
- MOVE.B MASTER_No(A6),(A5)
- MOVE.W (A5),D0
- LEA.L 0(A5,D0.W),A4
- MOVE.B MASTER_No(A4),(A5)
- MOVE.W (A5),D0
- LEA.L -LOG(A5,D0.W),A3
- MOVE.L X_POSITION(A4),X_POSITION(A6)
- MOVE.L Y_POSITION(A4),Y_POSITION(A6)
- MOVE.L Z_POSITION(A4),Z_POSITION(A6)
- MOVE.B ACT_ATTR(A4),ACT_ATTR(A6)
- JSR.S SET_HIT_AREA
- RTS
- PM_HERO_SHADOW:
- JSR HERO_MASTER_GET(PC)
- JSR.S SET_HIT_AREA_HERO
- BTST.B #BHSS_NAGERARE,STATE(A3)
- BNE.S PM_HERO_SHADOW_1
- BTST.B #BHS_JUMP,HERO_STATE(A3)
- BEQ.S PM_HERO_SHADOW_2
- PM_HERO_SHADOW_1:
- CLR.L Z_POSITION(A6)
- PM_HERO_SHADOW_2:
- JSR.S REDUCTION_MOVE
- JSR.S NEXT_ACTION
- JSR PM_HERO_21(PC)
- RTS
- PM_HERO_BODY:
- JSR HERO_MASTER_GET(PC)
- JSR.S SET_HIT_AREA_HERO
- RTS
- PM_HERO_WEAK:
- JSR HERO_MASTER_GET(PC)
- JSR.S SET_HIT_AREA_HERO
- RTS
- TAMA_SET:
- MOVE.L (A0)+,REG_D0(A5)
- MOVE.W (A0)+,REG_D1(A5)
- MOVEM.L A0/A6,-(SP)
- LEA.L (A6),A3
- MOVEP.W MASTER_No(A3),D0
- CLR.B D0
- LEA.L -LOG(A5,D0.W),A6
- JSR.S FREE_HERO_PWORK
- BEQ TAMA_SET_2
- ADDQ.B #1,SPECIAL_USE(A6)
- MOVE.L #P_SP2*10000H+C_TAMA_H21,D2
- MOVE.W X_POSITION(A3),D3
- MOVE.W Y_POSITION(A3),D4
- MOVE.B #0B0H,D5
- JSR.S PWORK_SET
- BSR TAMA_SPEED_GET
- SWAP D1
- MOVE.W REG_D0(A5),D0
- MOVEQ.L #1,D2
- AND.B ACT_ATTR(A3),D2
- BEQ.S TAMA_SET_1
- NEG.W D0
- NEG.L D1
- TAMA_SET_1:
- OR.B D2,ACT_ATTR(A0)
- ADD.W X_POSITION(A3),D0
- MOVE.W D0,X_POSITION(A0)
- MOVE.L D1,VX(A0)
- MOVE.W REG_D0+2(A5),D0
- ADD.W Z_POSITION(A3),D0
- MOVE.W D0,Z_POSITION(A0)
- MOVE.B WORK_No(A6),MASTER_No(A0)
- MOVE.B WORK_No(A0),TAMA_No(A6)
- MOVE.B #0011B,HIT_ACTIVE(A0)
- MOVE.B #0011B,HIT_PASSIVE(A0)
- MOVE.B ATTACK_LEVEL(A6),LEVEL(A0)
- MOVE.B GARD_LEVEL(A6),79H(A0)
- MOVE.B HIT_STOP(A6),7BH(A0)
- MOVE.B HIT_LR(A6),7CH(A0)
- MOVE.B DAMAGE_ACT_TYPE(A6),7DH(A0)
- MOVE.L HIT_SCORE(A6),LIFE(A0)
- MOVE.B #80H,HIT_TYPE_No(A0)
- MOVE.B #1,HIT_FLAG(A0)
- MOVEQ.L #0,D1
- MOVE.W REG_D1(A5),D0
- MOVE.B SPIRIT_OLD(A6),D2
- CMP.B SPIRIT_RANK(PC),D2
- BCS.S TAMA_SET_3
- ADDQ.W #1,D1
- CMP.B SPIRIT_RANK+1(PC),D2
- BCS.S TAMA_SET_3
- ADDQ.W #1,D1
- TAMA_SET_3:
- MOVE.B D1,SPEED_RANK(A0)
- ADD.W D1,D0
- ADD.W D0,D0
- ADD.W D0,D0
- MOVE.W TAMA_TBL(PC,D0.W),ACT_No(A0)
- MOVE.B TAMA_TBL+3(PC,D0.W),PALETTE_ADD(A0)
- TAMA_SET_2:
- MOVEM.L (SP)+,A0/A6
- RTS
- SPIRIT_RANK:
- DC.B 32,64
- TAMA_TBL:
- DC.W C_TAMA_H23,-1 0 H1 1
- DC.W C_TAMA_H22,-1
- DC.W C_TAMA_H21,-1
- DC.W C_TAMA_H23,0 1 H2 1
- DC.W C_TAMA_H22,0
- DC.W C_TAMA_H21,0
- DC.W C_TAMA_E53,0 2 E5 1
- DC.W C_TAMA_E52,0
- DC.W C_TAMA_E51,0
- DC.W C_TAMA_E43,0 3 E4
- DC.W C_TAMA_E42,0
- DC.W C_TAMA_E41,0
- DC.W C_TAMA_E63,0 4 E6
- DC.W C_TAMA_E62,0
- DC.W C_TAMA_E61,0
- DC.W C_TAMA_E13,0 5 E1
- DC.W C_TAMA_E12,0
- DC.W C_TAMA_E11,0
- DC.W C_TAMA_H11+8000H,-1 6 H1 2 HAOH
- DC.W C_TAMA_H11+8000H,-1
- DC.W C_TAMA_H11+8000H,-1
- DC.W C_TAMA_H11+8000H,0 7 H2 2 HAOH
- DC.W C_TAMA_H11+8000H,0
- DC.W C_TAMA_H11+8000H,0
- DC.W C_E5_FIRE3,0 8 E5 2
- DC.W C_E5_FIRE2,0
- DC.W C_E5_FIRE1,0
- TAMA_SPEED_GET:
- BTST.B #BPS_COM_FLAG,PLAYER_STATE+PLAYER_OFFSET(A6)
- BEQ.S COM_TAMA
- MOVEQ.L #6,D1
- MOVE.B SPECIAL_OUT(A6),D2
- CMP.B #17,D2
- BCS.S TAMA_SPEED_GET_1
- MOVEQ.L #10,D1
- CMP.B #23,D2
- BCS.S TAMA_SPEED_GET_1
- MOVEQ.L #14,D1
- TAMA_SPEED_GET_1:
- RTS
- COM_TAMA:
- MOVEQ.L #0,D1
- MOVE.W LEVEL_TEMP(A5),D0
- ADD.W D0,D0
- MOVE.W COM_TAMA_DATA(PC,D0.W),D1
- RTS
- COM_TAMA_DATA:
- DC.W 6,6,10,10,10,10,14,14
- PM_SP2:
- TST.B ACT_FLAG(A6)
- BMI PM_SP2_2
- TST.B HIT_FLAG(A6)
- BPL PM_SP2_1
- BSR TAMA_SOUND
- CLR.B HIT_FLAG(A6)
- BTST.B #1,ACT_FLAG(A6)
- BNE PM_SP2_1
- MOVE.B #0,ACT_COUNT(A6)
- PM_SP2_1:
- BTST.B #0,ACT_FLAG(A6)
- BNE PM_SP2_10
- TST.B HIT_FLAG(A6)
- BEQ.S PM_SP2_10
- MOVE.L VX(A6),D0
- ADD.L D0,X_POSITION(A6)
- PM_SP2_10:
- MOVE.W X_POSITION(A6),D0
- MOVE.W D0,D1
- SUB.W BACK2+Wx(A5),D0
- CMP.W #-32,D0
- BLT.S PM_SP2_2
- SUB.W BACK2+WxRIGHT(A5),D1
- CMP.W #32,D1
- BGT.S PM_SP2_2
- JSR.S REDUCTION_MOVE
- JSR.S NEXT_ACTION
- JSR.S SET_HIT_AREA
- JSR.S SORT_SET
- RTS
- PM_SP2_2:
- MOVEP.W MASTER_No(A6),D0
- CLR.B D0
- LEA.L -LOG(A5,D0.W),A0
- SUBQ.B #1,SPECIAL_USE(A0)
- CLR.W TYPE(A6)
- RTS
- TAMA_SOUND:
- TST.B IN_BONUS(A5)
- BNE.S TAMA_SOUND_1
- TST.W ACT_No(A6)
- BPL.S TAMA_SOUND_1
- SOUND #S_PUNCH_4A
- RTS
- TAMA_SOUND_1:
- MOVEQ.L #0,D0
- MOVE.B SPEED_RANK(A6),D0
- ADD.W D0,D0
- MOVE.W TAMA_HIT_SOUND(PC,D0.W),D0
- JSR.S SET_SOUND
- RTS
- TAMA_HIT_SOUND:
- DC.W S_ST_PUNCH3,S_ST_PUNCH2,S_ST_PUNCH,S_ST_PUNCH
- PM_SP3:
- RTS
- PM_DESI:
- TST.B STEP1(A6)
- BNE DESI_STEP2
- JSR DESI_JUMP(PC)
- TST.W Z_POSITION(A6)
- BGT.S PM_DESI_0
- MOVE.B #1,ACT_DEC(A6)
- PM_DESI_0:
- TST.W VZ(A6)
- BPL.S PM_DESI_1
- BTST.B #5,ACT_FLAG(A6)
- BNE.S PM_DESI_1
- MOVE.B #1,ACT_DEC(A6)
- PM_DESI_1:
- JSR.S REDUCTION_MOVE
- JSR.S NEXT_ACTION
- JSR.S SORT_SET
- RTS
- DESI_STEP2:
- JSR DESI_JUMP(PC)
- MOVE.W X_POSITION(A6),D0
- MOVE.W D0,D1
- SUB.W BACK2+Wx(A5),D0
- CMP.W #-32,D0
- BLT.S DESI_DEAD
- SUB.W BACK2+WxRIGHT(A5),D1
- CMP.W #32,D1
- BLE.S PM_DESI_1
- DESI_DEAD:
- CLR.W TYPE(A6)
- RTS
- DESI_JUMP:
- BTST.B #6,ACT_FLAG(A6)
- BNE DESI_BOUND
- MOVE.W VX(A6),D0
- ADD.W D0,X_POSITION(A6)
- MOVE.L VZ(A6),D0
- SUB.L #9000H,D0
- MOVE.L D0,VZ(A6)
- ADD.L D0,Z_POSITION(A6)
- BGE.S DESI_JUMP_1
- NEG.L VZ(A6)
- CLR.L Z_POSITION(A6)
- DESI_JUMP_1:
- RTS
- DESI_BOUND:
- MOVE.B #1,STEP1(A6)
- RTS
- INCLUDE WORK.INC
|