|
本帖最后由 yandagui 于 2017-4-21 18:58 编辑 / _" Z. J3 `0 E7 F! @
- R# n0 \. c" K" k. s
[FC][最终任务][END选关]" ~/ P" T7 }& |9 S: s
4 L: Y0 }: @ R+ i( y
时间:2017.3.299 X5 v: B: `; ^: S# w- m% C
作者:FlameCyclone
: g; y) T* e# q: a0 W1 j4 W6 `内容:
: w; |4 m' C4 C: a) o7 | 1.关卡选择: 标题时,左或B减,右或A加(1-5关);. P: D& w2 q( u& }5 n5 l! s7 s
2.无敌锁定: 暂停后,按上键切换;
0 _/ `4 y9 d! Q2 Y" y+ a7 e 3.生命加满: 暂停后,按下键切换;+ @( D2 u3 C& x4 y$ a: x, D, S3 V
4.速度调节: 暂停后,按左键减,右键加(1,2,3三级);
1 D9 l9 o9 g$ u* F1 w+ E+ N 5.子弹切换: 非暂停,选择键切换(普通,W,L,B);" d, \4 O) {. R' c7 d. n9 o2 v
6.B弹数量: 暂停后,按A键切换(1个或2个);
% ]4 j$ w4 v* u1 O 7.副武器类型: 暂停后,选择键切换(普通,W,L,B),非普通时子弹方向是向右发射的;& h' o9 `( g- v( o) V& a& I
; c6 m9 a$ k1 I: y. @# V& x% p
. E1 I C! B) m5 C+ ]1 y
4 V' Q$ X7 |. u3 n( c9 \/ p2 H Q
2 |. r) m7 Z3 n) Z, w4 i% M" V0 I% y$ r2 z& r$ ?! T
8 D2 J, y5 V" F$ JFlameCyclone.ys168.com" e6 c2 O# r7 S4 q/ P
www.nesbbs.com- ;[FC][最终任务KEY][END]3 q* E; R6 V: a. y
- button = $04 ;单次按键+ }) D5 A; D: @" J1 B1 j
- flag = $6000 ;功能开关标志3 O' c# X. }. b5 t/ z- w
- pause = $000E ;暂停地址
, ?3 F2 B) Y: R) z" y7 m* y
" o. ?! [. h8 B! ~0 V- .ORG $8000
& x* M/ d p, D8 w6 l - LDY #$08 ;自带的按键程序7 ~7 Q( h7 Z4 Q' t
- ADDR8002:
' E8 v( a1 S1 h4 i# u9 Z - LDA $4016,X
2 [( E9 g) Q" P - LSR
( }5 E9 p2 b6 d5 I! r. y. w0 f - ROL $0021( d' D4 M+ ~ ^* m0 Z/ w% X
- LSR
4 g/ }! Y3 U4 e8 l( j - ROL $0029) a+ N! p% L$ G0 y
- DEY
) }2 Z. m9 L' i2 t% t* a - BNE $8002+ H; v. m* l! A) m8 {
- LDA $0021
T$ O6 i5 Y: U/ z7 M6 V - ORA $0029
6 ?3 i1 d: y0 @& b7 @6 C' b% t - STA $0021
8 v( A {, t4 `+ K - LDA $0020
1 b( G6 V# F1 {: Z - AND $0021
! H6 Y7 [9 K" \3 U - STA $0020
, o* i! W) S7 O: D0 h( q$ O+ d. i( ^ - LDA $06,X
7 P# g; s; D' b- h/ R! w) E3 D - EOR $0020
/ t D& ]( W' l9 P0 |4 X0 z - AND $0020! ^0 `' }( ]; |7 @6 U
- STA $04,X
8 S! e: _% u0 z% k) G - LDA $0020, z, H; G# Q2 \7 p8 y0 @5 ~
- STA $06,X7 b [* U7 Z( i0 M$ ~/ ^; L( b
- JSR KEY_OPERATE
( O6 a' [7 c6 Y7 T1 q - JSR Function ;功能调用. J9 }9 n; S; g, z( F7 h
- JSR Weapon ;武器切换调用
- w% {+ Z5 u9 @: S2 \ - JSR Power ;威力调用$ j. M5 S ]- p
- JSR BULLET_NUM ;子弹数目2 _/ `6 P+ J9 Q4 q" \
- JSR BULLET ;副武器类型
5 Q3 A2 m# Q r5 f( J6 W - RTS
/ u6 y( n& N# f) y - , E) }0 L+ M x3 X9 D. ~" h- y3 B
-
5 |: x% u8 E+ u+ m0 E2 w
* T! ?$ `' p2 S% r% b- p% B- .ORG $8050! ^( G6 P+ }+ B7 E" l, L' F
- Function: ;功能* ]+ g" f( D7 T, ~5 |
- WUDI: ;无敌# A0 y' h @7 W6 I1 e) g0 }
- LDA $6000,X
8 I, V: y4 s; P" z/ C - AND #$08 ;开关判断
7 G2 N1 Z' X% e6 n2 J3 {" [ - BEQ LIFE7 Y" [ Y5 R) V, |3 g
- LDA #$05- U! f2 I n8 j( {
- STA $05DC,X ;无敌锁定, w' |) N) M' c5 Z
- LIFE: ;生命
! q+ y' g- O4 X1 P( n) Z - LDA $6000,X Y6 @( x9 D9 o- ]
- AND #$04 ;开关判断
& M, ?) k1 X" f% ?4 q' u - BEQ FUNRTS- O" t* L2 X$ t: Z8 `8 @" g6 O
- LDA #$05/ v" H& n2 v- ]& } W
- STA $1C,X ;生命赋值
' F8 N! o- b. e- }! v" F% T: j - FUNRTS:
F) c- K( S# k' D4 w) L2 U% D# l2 g - RTS9 j$ R- O6 w1 X6 c
-
) P) d; E0 Z( P+ I% `/ K( I! Z - Weapon: ;武器切换
% S7 B" ^3 g; a9 v3 w6 `. I) U - LDA pause ;暂停状态判断, V( M; g: d, i: I' |* N
- BNE WEARTS s& b( M7 |" ~1 [: O O
- LDA $04,X
$ o" `$ V& y6 z$ E! M/ C( E0 K - CMP #$20 ;选择键判断$ g: I1 X' }2 y( p' x
- BNE WEARTS) ~5 V. ^/ d$ ?8 [ O* \4 B1 f
- LDA $12,X
% V9 A+ n) t" v" y - CMP #$03 ;武器值判断
1 Y7 r7 O; E/ ^, S% x - BCC WEAINC
/ ~3 i- [$ n: c0 l - LDA #$FF! @- {. y7 l/ }4 T [; f; d' ~* N) K
- STA $12,X ;武器重置( y2 d+ N3 v u; m4 E( ^
- WEAINC:$ F$ O) B5 n- f- o! a9 M# _
- INC $12,X ;武器增加
. D& \9 M! q" k# Z# n - : _+ x7 l) r/ G* W- n% i
- WEARTS:
) K7 Z; F( ~4 E V - RTS; G3 b: \; K& H3 `1 O6 C
-
( O: a4 R1 I% i- Z4 S1 r - Power: ;威力+ f5 ^, H1 C8 n2 | P
- LDA pause ;暂停状态判断
$ m- v& g$ g* E - BEQ SPERTS
& a8 ~5 m9 k2 I8 t4 C- G - BUT_LEFT:
+ f+ t& p! m# n! p - LDA $04,X
* r% a# f. J: t: W/ s3 j - CMP #$02 ;左按键判断$ [, |: v4 }- f% J" ]
- BNE BUT_RIGHT8 p7 E/ L) i0 W* P3 w/ n
- LDA $88,X8 r5 O) C p: W' Z
- CMP #$00 ;威力判断 p3 Z! e' T$ Q* j
- BEQ SPERTS( Q ?; q) D1 w d) @
- SPEDEC- f- D1 z; U9 O, J
- LDA $88,X ;读取武器值# v8 K7 K: O& p" F* H
- SEC! n% }$ A7 T5 D. R8 ~
- SBC #$08 I4 y* U C! z0 [9 E2 x* J# E
- STA $88,X ;威力减小
" |/ X% j. ?0 p, U4 l - BUT_RIGHT:
r# n. }$ @3 {( l$ u - LDA $04,X
* ^3 ?' a8 P5 p7 [, m! J2 A - CMP #$01 ;右按键判断
2 p8 b4 U" V2 a3 N% a) d: C0 n - BNE SPERTS% e3 }! j7 U' X+ r6 `
- LDA $88,X
. y1 V5 I0 y [# L1 K2 i - CMP #$10 ;威力判断& L- a6 N: B% ^
- BEQ SPERTS
' J8 {& ^4 n; }5 D- U2 V2 }5 i - SPEINC:, ~9 r* Y- X0 G# s6 }- w4 ?
- LDA $88,X ;读取武器值
3 F( w4 U* H( n5 b5 ^7 j! T: _6 g - CLC; J& }5 k+ g3 L0 P
- ADC #$08$ q; v- r- ~4 O. N0 d* s
- STA $88,X ;威力增大
% v. M0 }' y1 J# p - # B$ S, l! E: s3 n
- SPERTS:: C& h- P2 ?) J0 H% g
- RTS
" C9 [$ i p8 [; V: |1 q - $ H- ?5 @. i2 d: X9 ~
- BULLET_NUM: ;子弹数目
5 ]5 k3 T- V, u - LDA pause ;暂停状态判断
6 n; ~1 M) g$ I# A - BEQ BULRTS* }6 h0 {0 U2 @
- CPX #$00 ;主机玩家判断4 d H! @" j1 D1 N9 O+ l
- BNE BULRTS( Y/ f4 Z1 H$ S4 D+ J1 k
- LDA $04,X ;主机玩家判断# a2 H" j% o7 r9 w0 W/ ?& h
- AND #$80 ;按键A比较4 q8 H( }8 O4 }4 c9 A
- BEQ BULRTS' P8 {0 |. [; o& j3 S; X0 ?
- LDA $87 ;状态判断1 i9 X1 \" _8 @, m `1 t
- BEQ BUL_2
. O" S: V& I0 x# w7 t# U4 m& P - BUL_1:
( e( z" D, @7 T1 F- k1 ~ - LDA #$00
9 k' P8 `( \; i3 N4 V0 f - STA $87 ;1发子弹6 N, S8 z& |; }7 L6 N6 | Z
- BEQ BULRTS3 B8 E0 r5 g: R- V
- BUL_2:
o6 B5 h- z9 u6 `9 S - LDA #$01
! ?0 k9 x, P9 U+ [; ]. ?0 f/ q - STA $87 ;2发子弹& R4 B1 z" ~; w& D/ X! e
-
* X7 `' D9 Q3 X4 C - BULRTS:
' I6 U6 S' p5 L$ h+ T$ U z; D$ { - RTS
! O1 A2 K# x) N -
' T$ g, i& ?. W! R9 o/ R- w; O, F7 Q - $ T5 I: B" Q3 ?6 I1 i
- BULLET:
0 g1 k O0 K3 Y! E/ b# y. t - LDA pause ;判断暂停状态, d8 W2 O, Z# Q8 _ c. E& v2 |$ N
- BEQ BULLETRTS
4 @7 n' Q/ Y: m5 x$ {0 K* n - LDA $04,X
5 O" Y4 u# g( Y2 D, s+ T7 w - CMP #$40 ;按键B比较
0 d( |; L$ t7 |& R6 @+ L! n3 X/ L - BNE BULLETRTS
0 N0 l5 b) J" u9 } - LDA $6002,X ;读取副武器
4 d. d( \; d* ~/ m7 L4 a" a* j - CMP #$03
. S; ?: u7 d3 y) G+ F5 Z E - BCC BULLETADD
5 X% T9 C: A' T& ?+ M: i/ C: [ - LDA #$FF
2 n0 `2 z0 W, ^- W0 A+ Z - STA $6002,X
3 h+ U" g) x+ |' ~& p - BULLETADD: t5 j: l4 A- a( {! ^
- INC $6002,X
5 U) x' h7 A5 ?0 b* [' ` - # E% u2 h4 e5 \. V
- BULLETRTS:$ P, o8 I% Z4 e6 S2 }5 K
- LDA $6002,X `( A- x. G: N/ {
- TAY: {' F" T6 j) u1 T) x @+ P; g
- LDA BULLET_DATA,Y7 D& ]6 k( }& h
- STA $6004,X ;写入副武器数据
; q% X' X! m- K$ c( l% k4 K6 Y( N5 s2 D - RTS/ R2 M8 B3 x% x! D( z
-
0 Q+ j) L& u$ R7 C) v8 ~* z% p -
?8 W4 p/ m" ?9 U" M - BULLET_DATA:
# w0 ~- j T) I+ c$ K9 s# q - .BYTE $06,$02,$03,$04
& K/ c" T7 O7 `- o! y f2 _; Z y2 Y - 2 C: o6 n: P+ S" w& W9 @% f* O: U7 N
-
# |& N2 J0 j1 N -
; F) n0 n* g. J' ?, }( H - KEY_OPERATE: ;按键开关操作; C- w# [$ n1 n
- data_protect: ;数据保护
: G+ L4 m1 f0 [: T8 C - PHA
4 }; o, _4 x$ ^/ z - TXA
& v9 d9 R; E2 ^' m8 }4 B - PHA2 @6 g* J! W9 u9 b7 I$ c+ M
- TYA
4 ]7 Z# Q/ C) }/ G5 y p - PHA
: Q* F4 a1 k7 `
, S; g+ y+ g* A! S8 f/ h- FLAG_INI: ;开关标志初始化
! a, O h% j; P9 \$ l
5 d+ _+ o, K) G7 ]. K- LDA $600F" N; w% Y4 a) {6 h6 V3 u
- CMP #$016 S" s& K5 G5 ~! y0 ~: ^2 x
- BEQ pause_cmp
* q/ O1 a' f1 D - LDA #$00
3 ^# f6 C( M9 ?) o - STA $6000: s+ H8 }4 W- _; L
- STA $60011 h* c9 J3 X) v" Z2 a
- STA $6002
! _# f. B. H! S0 X1 U7 W! L - STA $6003' V3 ` F0 Q5 S/ d( C8 t
- STA $6004
3 A/ s6 E9 d0 z0 J( f - STA $6005
8 b; v E' J" { - LDA #$01% M1 K. y' W- I. ~9 }" B4 h
- STA $600F
- a; `6 ~2 l/ ? - 6 r* S: s4 i6 B
- pause_cmp: ;判断暂停状态5 A3 t5 {1 d1 }9 D3 T
- LDA pause
0 C6 B9 r, z" B C - CMP #$01 ;判断暂停状态
" l7 B% T9 h! H! c& I - BEQ button_press8 y& k* k3 j& K1 `6 F* r
- PLA
; B& ?( P% s5 `9 q& F$ B3 j. ` - TAY
# m5 \- m) A; h) `' F% S2 I* E - PLA
1 _* E, Y2 t. D$ f+ r9 w; h/ m - TAX( H8 G! X4 N. ^; A& ?7 I
- PLA) Z, a& y4 _) ]- s$ q+ ~- y2 u
- RTS( j* B, r3 z+ X
+ t: Q$ Q5 e* X X+ i8 A! N- button_press: ;按压操作' I7 x0 c& x+ g, L
- ini_Y:7 f9 V( w. `6 k/ Y
- LDY #$00
# D8 M! U: t9 H* i* ]+ U, y - button_cmp:4 E. K D0 S1 J% N/ B$ T
- LDA button,X
$ J4 ^# P# [1 R( D2 Z, Q - CMP ora_data,Y
3 @4 i L. Y# b" C) I - BNE count_Y_cmp1 M8 e. H: K' @& D4 v1 {8 }/ I: W
- flag_cmp:# M T9 \& k) r
- LDA flag,X
9 m) r6 V, Z5 H9 ?$ y - AND ora_data,Y# V3 d2 o/ x( Q
- BNE flag_and
$ U" e0 r' [/ u' K Z& Z - flag_ora:; `' Z6 o" O, |9 z
- LDA flag,X+ I) C) B! G1 f8 V5 m. I! d" r
- ORA ora_data,Y1 \1 b2 W; j% u0 J# x
- STA flag,X
4 _5 D/ C" X- i - BNE count_Y_cmp: _ N$ C& P3 |( S" s8 ]. f
- flag_and:2 j& i8 Z/ n5 M
- LDA flag,X
$ b9 M3 J# |9 p% n - AND and_data,Y2 K/ H0 W" ]5 M; b& y% _
- STA flag,X- F( h/ D7 {7 C
- count_Y_cmp:
8 _1 ?- y/ _! j( Z4 [5 M* B - INY: J+ S$ m/ v% E: `" v# Q$ n, Y
- CPY #$08' y5 y7 j+ O6 }3 A; K( C
- BCC button_cmp: y W) E; {! N' q; K
- c' @6 e" Z1 f$ X& I3 @: A
- data_extract: ;数据恢复4 ]. H6 s a3 ^/ J# X/ K7 a+ H
- PLA9 L; h7 B5 q. R4 x+ P
- TAY
0 f4 k4 G" M4 o3 ~1 s# J. T - PLA( ]" O# k P- c$ s/ Q5 e
- TAX
9 C) j0 |. D( y. \' M' ~& c - PLA1 k+ {. o) C8 \# [5 x; c% s
- 6 ]0 U3 s7 U/ Z$ B2 G6 n( m* Q3 |
- return:) }, ]. \6 w6 O) D
- RTS7 y& e0 x1 q+ d' p
-
; z) q* e# D& A* `# ? - ora_data: ;按键相或数据/ J9 A& ~7 W1 o! m2 s1 A, T; _
- .BYTE $08,$04,$02,$01,$80,$40,$20,$10
`# u6 i0 t2 L' W - and_data: ;按键相与数据
" x+ [0 g2 L [% [* f( D% X - .BYTE $F7,$FB,$FD,$FE,$7F,$BF,$DF,$EF( n% o0 U" w. W/ s/ n& f
- 4 t6 u' ?% E& S2 y
-
# S; d" ` Q$ [# i, A6 H -
( p5 S) l- g7 w2 |/ N -
- I; n5 ]: a& E" g0 D; w" ~* v: W -
9 j2 E' w/ x P- d- w3 y - 2 e: u$ t6 C4 X; C0 Y% k
4 G1 }4 g. O! Z- 6 F% l" W* \+ O3 e7 F7 ]
; N6 ?) V3 i) b0 D/ ~5 u- .ORG $C264 ;自定义的MAPPER2切页程序* U, n o+ K x s4 Y; K+ c" [
- PHA
: @9 \, d5 O. V. Z - TXA) ?$ u9 d4 X; Y) O- Y# o% B
- PHA5 v: z# W) ` D6 ?/ {1 `0 u1 w4 |
- LDA $0066
6 L! B5 ]* A, Z% n# l2 T - BNE ADDRC280
) h$ L/ a9 n5 @ - LDA #$076 { E" f, V7 z- [4 W5 y5 n9 k* q! t
- LDX #$03" X$ i# p1 |3 o0 R; A
- JSR $CD9B ;自带的切bank方法
* H) E& t4 \4 M# }& w8 w - PLA X _' J: s4 b: N2 X& n U, @0 m
- TAX
% Y$ P3 ^0 e }" U' D0 D5 o: E/ D6 P - PLA; \! J. |$ R1 y+ e5 m
- JSR $8000
: w$ S; x `8 d - LDA #$06
% f0 \1 \) {- e5 N3 q+ T - LDX #$03: _' N0 c# C1 K
- JSR $CD9B ;切回原该切得bank(可以不用), o, U7 [0 o9 F ?3 j' C
- RTS
& c' ^! F" k; R - ADDRC280:2 X& a1 B' E; @+ l p0 }# O0 O& @
- PLA
8 e- e% h9 j' q7 S: g8 J2 W; ]! B) t2 a - TAX j( s- t- \+ [7 B Y0 t' f
- PLA5 C. p3 p: X" m: @; K( h- z( o1 ?
- RTS# _4 O- B$ G* M8 j, {: n2 ^6 Y
-
: X8 \# v6 b; G6 W1 J -
0 R! Y5 F: B1 w5 g& w: ?5 }: m: ] - ;[FC][最终任务PPU][END]4 H! ?' p7 k. \8 c2 w r% E
- .ORG $C056 ;跳转到PPU重写程序
& _3 t0 s0 l" p% Q7 Q1 E - JSR $70004 T0 a/ D y6 v3 g; X7 O' M
* j' Q( o3 M1 M$ c- .ORG $CEBF
0 b- S) }8 q2 P0 Y2 t4 ? i: C - JSR STAGE_DATA_WRITE ;跳转到关卡数据写入
& C4 s( f2 u. x% l( G6 w - 6 q) g8 Q; T7 Y3 Z. A+ D3 S
- .ORG $E4600 z, V9 K) l' S# J/ }
- JSR BULLET_DATA_WRITE ;跳转到副武器数据写入
& K& a. `; Y1 ^0 f) Q& Z; l( X9 @ - 9 |; z6 [* g3 h* Y/ v+ F# f9 ^
- .ORG $71F03 u4 S' \, J4 j9 V
- STAGE_DATA_WRITE:; w5 o+ s" u! E, v
- LDA $6010
+ m5 D O: l, q# B7 K, {- p, o - STA $1E ;关卡写入: [: [0 e+ c5 T
- LDA #$00
$ ~- |2 [" X0 ]. y. | - RTS, i' X) f6 G" C! b9 e9 q0 M* [( O2 g6 n
- .ORG $71C0& h9 k1 |, z6 W7 M
- BULLET_DATA_WRITE: ;副武器数据写入. J; q' d/ ]8 g: M
- CPX #$0E; t8 a8 o' w; Q' E4 j3 f4 I
- BCS P2_BUL8 L- I9 v! U2 b& I0 P7 [4 P: g
- P1_BUL:
8 g9 S7 t6 z+ }# i - LDA $6004
* i- T; c; i& C - JSR $D7D0 ;P1副武器数据写入. V+ o% {3 A) Y- J6 T3 m
- RTS
! ]; ?$ I; l0 F; X% h0 X, E: C, O# U - P2_BUL:& e) m1 V* O- E" d+ i9 h P: L
- LDA $6005
3 V& n( x' A/ I; l - JSR $D7D0 ;P2副武器数据写入7 s( t6 ~4 }7 e1 }
- RTS/ C! r0 L/ ~* w2 W# r
* l% z' k) T! a- b, j, e% |% D# Z
. h" ^# O/ ]5 F0 \5 Z! N- .ORG $70002 T) f, S1 }! m* r
- 9 u; ^ q) E7 P
- STY $4014 ;补上覆盖的精灵写入指令
; i! R& l+ {. `" G0 k - PHA
0 P) n! S* G; E* x/ t/ S - TXA
l: X( F% d m5 z; a - PHA
6 G5 ?5 x& R9 {' e7 q ^ - TYA$ r- p3 Z3 a) ^, ^
- PHA
0 g9 j9 x+ q% [0 r, [. l# Y - LDA $0C
* g$ t: N& X) U' u - CMP #$01 ;比较是否为标题画面; X+ H8 N" F. M
- BEQ PPU_STAGE
3 P ]: I, J. ] | - PLA
" _/ M" V0 k4 V! Q4 v - TAY7 @; t6 L2 z& E' O w
- PLA) I5 d* }6 @; T( j" @7 `* k
- TAX/ o6 [4 \& a8 `2 B4 Y: @0 b& b5 }1 y
- PLA' U# e: j" e5 L7 H4 [" o& ~, f
- RTS
5 b1 z6 m' a- R- t2 o - PPU_STAGE: ;STAGE显示程序0 a. k6 ~6 l& B0 d5 ~
- LDA PPU_ADDR_DATA& J' d- l+ F, j" H" G1 s; n7 ^# q/ z3 r
- STA $20061 i. m# }9 I/ r) |/ F
- LDA PPU_ADDR_DATA+1
7 z0 M0 |+ D3 h+ S% b - STA $2006 ;坐标设置! K$ g/ l5 i7 z( E _
- LDX #$007 j. \4 r, y9 Z8 f& }' g1 a
- PPU_STAGE_WROTE: ;写入STAGE字模
7 l: b1 ^4 J1 q. W/ S - LDA STAGE_DATA,X7 a) ~2 X s2 a6 I
- STA $2007
! Q; t$ X. r7 ~! G: G - INX/ r' K' e) r+ W" y1 l
- CPX #$06
$ i0 k( M6 T7 i& n4 l8 J - BCC PPU_STAGE_WROTE7 V0 v7 E. O) x" l7 _' b
- LDA $60100 U& L6 G+ P1 p/ b( k ]) H5 h
- CMP #$FF ;关卡数据初始化条件判断" g4 \& [& [/ z
- BNE KEY_B# @1 y4 a" H- o1 Q. r
- LDA #$00. T6 {4 P4 K5 c( _2 o% P
- STA $6010 ;关卡数据初始化
" ]& g) s$ H M% k2 G: h0 b1 n - KEY_B: ;关卡减少) B! p2 {$ y# U1 _2 K7 Z
- LDA $04
. |$ G: ]8 s4 S+ \; a$ @ - AND #$42 ;按键B或左减关
9 [4 C% i I2 p6 d% D1 i. \ - BEQ KEY_A+ V) M7 x! l( l/ b, t
- LDA $6010
5 I. P* c6 _; `& ~, r% T% T - CMP #$00 ;关卡比较
1 R% S& H1 I7 ]0 J - BEQ KEY_A! g0 m+ J- l* J3 v
- DEC $6010 ;减关
3 A! E g" y- {! K* I1 [ - KEY_A: ;关卡增加% m0 s4 r7 ]8 O H3 q) `
- LDA $04. O+ S; K0 S/ e# F T
- AND #$81 ;按键A或右加关: [# i. h* F8 P9 C7 S) ?& l, s1 o
- BEQ PPU_NUM_WRITE
7 J! p' y! b. E- T3 V- v - LDA $6010
" I( R9 ?* u4 o, J9 f - CMP #$04 ;关卡比较
( X% g' l# n5 P& F! f& p9 m - BEQ PPU_NUM_WRITE
5 ?+ G3 B. F" L2 i& X8 N* b - INC $6010 ;加关/ [9 \9 j' x9 y2 h5 u' L
- PPU_NUM_WRITE:3 A3 l7 D+ N, x7 L
- LDA $6010$ \9 m1 i+ M0 d u$ W7 R1 C
- TAX
% I* e. V. j; ] - LDA STAGE_NUM,X ;写入数字
) m0 C. l* p) r" E1 I( U3 K$ M - STA $20076 f% C1 k0 F. ?3 d v3 e# Q
- PPU_RTS:4 |0 Q1 }' }& O* [' i
- PLA, |3 F; q8 D; z4 e- C5 q
- TAY
) j/ E; t( E4 C - PLA
6 J+ z, ~0 @ f5 z - TAX
4 ~; T1 E) t% D7 k/ @+ P2 O - PLA1 z, e% a x$ v" [: E" e; t
- RTS
: C: ]" q: `* h; U2 e/ O - " @ ?/ B9 |, x6 ^2 Z
- ; ?6 ?4 u6 ~0 @; O7 _
- STAGE_DATA: ;关卡文字S,T,A,G,E,字模数据
# @( [ j) F* X - .BYTE $EC,$ED,$DA,$E0,$DE,00
- ]' a4 K; e7 g8 y - STAGE_NUM: ;关卡数字1,2,3,4,5字模数据
& |: c' e- R* }2 U. c& P( [1 ^/ x - .BYTE $D1,$D2,$D3,$D4,$D5
( k6 Z2 p, f7 R2 }5 _ - : s, ~, H& [ \4 w8 m8 G V/ o
- PPU_ADDR_DATA:. o3 [- ~( Y2 {* f+ J* b' d; f
- .BYTE $23,$0C
* p' |# E& H8 J# Y0 N7 C( s9 I -
8 _2 k' V" k$ i8 l- P/ G' k
复制代码 |
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有账号?立即注册
x
评分
-
1
查看全部评分
-
|