|
本帖最后由 yandagui 于 2017-4-21 18:58 编辑 : I" i% P8 o" Y8 f6 d u4 B9 U, `3 \
4 d3 Q; ]% O, E% w3 b/ `$ h. R [FC][最终任务][END选关]) u/ ~% {& D: C5 i
- v( l6 q( F( d# j J$ ^时间:2017.3.298 W7 e6 ^) T% D9 P4 c
作者:FlameCyclone
& D5 n" P9 L( b. [. S- l- S- b3 i内容:
* B+ z5 h3 f& e$ j8 M1 b( l6 ^ 1.关卡选择: 标题时,左或B减,右或A加(1-5关);8 @0 E7 u& o% [$ @' }; r2 R
2.无敌锁定: 暂停后,按上键切换;
* C* w* G, Z$ R+ }, X 3.生命加满: 暂停后,按下键切换;" A7 L- q# _3 H2 k
4.速度调节: 暂停后,按左键减,右键加(1,2,3三级);
( u. p' s0 g( w. X& x0 x 5.子弹切换: 非暂停,选择键切换(普通,W,L,B);
: s7 F# o4 z+ i: h8 S$ t5 h 6.B弹数量: 暂停后,按A键切换(1个或2个);7 k5 r$ X: ^6 I9 Q
7.副武器类型: 暂停后,选择键切换(普通,W,L,B),非普通时子弹方向是向右发射的;
& z. ?1 ]* `. {+ c& f1 {7 ?* ?. s) l# T% v
1 j [7 P' o% ]
+ @$ c& R2 l" ^; q" z2 V' N
; L" b: A. W2 _. ~6 P, r6 W: y* |# o) N! `7 \
: }" L3 k) Y5 q- S. R- P
9 Q/ H* G1 }! a/ y* W- kFlameCyclone.ys168.com) D: S" Z7 A/ b) C6 E! C1 E( u
www.nesbbs.com- ;[FC][最终任务KEY][END]! a8 l6 h2 z: H/ ~7 k& t3 D
- button = $04 ;单次按键+ b' C7 \- r: c) ~
- flag = $6000 ;功能开关标志 Q: a' ~7 u( v
- pause = $000E ;暂停地址
/ e& F+ F4 Q$ r+ k a1 ]7 W
. }' q7 S8 e8 t; r- .ORG $8000 }2 i& A6 I F
- LDY #$08 ;自带的按键程序
/ v) f; `5 o3 F/ f o. e, }; h - ADDR8002:
: C; G# S/ A" ` - LDA $4016,X+ i; G6 n% b6 P' d& f! f
- LSR3 h! M3 I0 V- {8 p% E- ^6 z+ {
- ROL $0021
+ x8 M$ f6 V, H8 _ - LSR
) y" B* L0 F: f$ F8 Q - ROL $00297 ]7 \: m! X }' h: S' f; p4 G
- DEY
H9 q/ ]( q) d/ J4 b# p9 C+ A3 _ - BNE $8002
: ?9 F- C/ w5 {* P0 h - LDA $0021$ S, ~- a" ~+ Y' k' ]" C
- ORA $0029
; ?* ?$ @: p/ ^' |: p - STA $0021
1 W6 G7 ?/ J7 A1 b - LDA $0020
0 F! P- L' T/ b) J- d - AND $0021
1 z S: @6 t% e& g: j/ w2 _ - STA $0020, v/ b9 P% S2 `/ o* f8 R
- LDA $06,X+ L* S2 B ~' U, X8 x8 O7 e$ r
- EOR $0020
8 B6 k7 C/ m& c$ q7 K* u- ?& X! }& q; ^ - AND $0020
% \8 ]" I' u* h# I - STA $04,X" c# X8 g" w3 H2 J
- LDA $0020 j! x" _$ b( {: y
- STA $06,X* p, T, E, y A! C8 o$ B6 U8 M8 V
- JSR KEY_OPERATE9 R& W R' Q# K4 h9 f
- JSR Function ;功能调用
: D4 B4 U; n# q a! L/ I - JSR Weapon ;武器切换调用
7 P9 A( t+ s/ f - JSR Power ;威力调用' @- k, z/ n5 C! ^3 ^8 `
- JSR BULLET_NUM ;子弹数目
0 @/ b% N' \6 L) j - JSR BULLET ;副武器类型
8 Z; m) j1 N H% D2 n9 M/ _ - RTS5 b8 S5 g3 F3 F" ?: t. O
- ; z" C; k% J7 ? `' z
- 4 ~! f. M, Q% Y' u2 w
- 2 b2 M# D' Z% j m. x- o
- .ORG $8050- Z! S, O& ~3 Y; }8 j l; ~; R: F
- Function: ;功能
) ^, y3 l( C1 b - WUDI: ;无敌( A+ j$ s4 f' V1 B: d" N5 A& i
- LDA $6000,X+ Z9 [6 |2 e& U z: u
- AND #$08 ;开关判断
0 R3 U/ c+ U9 i( z$ o& W - BEQ LIFE
x7 ?2 O! W, K& E - LDA #$05; S4 d" R& d; e' C
- STA $05DC,X ;无敌锁定4 i- L3 j3 W( @/ B" m
- LIFE: ;生命( D5 `% y+ }& e, l/ G j* |/ F
- LDA $6000,X" M u' I/ b; B) p7 z( \, b
- AND #$04 ;开关判断
# E: d, a. v3 M' k - BEQ FUNRTS
0 j) O3 N/ o0 x' U) U( T - LDA #$05# n: J9 k5 }1 u# i: e6 @
- STA $1C,X ;生命赋值7 K9 i9 \* l+ J7 h
- FUNRTS:
5 q4 N+ W0 v( V6 g - RTS9 q, J# T* {, S; O
-
; y3 o1 v5 Z% M - Weapon: ;武器切换
U: y; U: V2 [3 W6 O# L - LDA pause ;暂停状态判断
$ t# E4 s C/ Q T' g+ k. u - BNE WEARTS0 E$ ^7 f7 ]0 j) D( @
- LDA $04,X
, {, ]2 c7 x" b4 { - CMP #$20 ;选择键判断
# R7 `' g8 `7 m# _0 [* ] - BNE WEARTS
/ a. X5 g+ G/ Z - LDA $12,X
" z# o: W7 _" v; H - CMP #$03 ;武器值判断
7 G* z& _, N9 X. @6 m3 S - BCC WEAINC4 [* n+ t- D# I% r2 R/ L- z3 a
- LDA #$FF; x. w& a& j+ A1 }7 j
- STA $12,X ;武器重置) k* b. D1 @" Y, u1 U2 S- d
- WEAINC:& J( s+ b& @% V- G5 X. w* M
- INC $12,X ;武器增加
& w8 @, ^* `) D -
. o( F# i+ a* i8 B# U0 O; {1 [8 R - WEARTS:+ j# v0 N7 q! o2 c) k
- RTS4 y; d- M$ J: ?! t: a( {" u$ T
- * R7 F+ i9 P% d5 K7 N- G
- Power: ;威力
% |) Q9 e4 q0 l' p N# c - LDA pause ;暂停状态判断" O2 Z6 V8 E) y: p+ \1 h2 o. o
- BEQ SPERTS
3 `0 B9 |1 O+ ~" P7 d - BUT_LEFT:
# t L/ W4 _ e+ k3 z) a - LDA $04,X6 J, H% G$ c& }& g$ V: r
- CMP #$02 ;左按键判断8 T6 I4 M; S0 ]# X( Q% |) n
- BNE BUT_RIGHT: m% Q) L0 k6 f9 S; i
- LDA $88,X
; Y- h# W' e# g0 e" W1 P9 x - CMP #$00 ;威力判断
& J0 }* x9 ^& |' p* s! O - BEQ SPERTS
% n6 o- J F, Y1 V! `3 i - SPEDEC
* U/ R5 S, U6 N4 R" J2 | - LDA $88,X ;读取武器值
8 W7 G/ k; f; R( H, C - SEC
+ l& q3 Q0 v- [. X - SBC #$086 y+ y- n% K! _; K3 P0 ^" D
- STA $88,X ;威力减小& ~% O3 [+ j& T3 a- z5 G R0 b
- BUT_RIGHT:
$ v- i* K9 }4 [' O: q - LDA $04,X
) u' f+ L4 W$ ]4 z5 e7 {& q. f6 C, S - CMP #$01 ;右按键判断9 I5 |1 D5 A! z5 t P2 |
- BNE SPERTS
- y4 H/ ]5 a/ K- t! l1 u% h/ ]! b - LDA $88,X' r) ^" H! _8 l8 |% ~& _1 C
- CMP #$10 ;威力判断6 U7 Z/ z2 `' z- f1 f# A- N
- BEQ SPERTS+ \ s) Z7 |: p& a& W) @: J" s
- SPEINC:* |& \2 C9 v; H
- LDA $88,X ;读取武器值+ U9 I8 ?. {: o2 K4 `. f$ |7 c
- CLC/ g8 |2 t# q) g8 T/ r' ^# |0 h! L
- ADC #$08
- D6 ^1 I# a6 o! b* W5 l - STA $88,X ;威力增大
3 Q# X( U2 N+ B% H - * l( c3 N& K9 q! i2 ?) O0 ~2 @" b0 H d
- SPERTS:. r, p7 Y% u& T z/ k) I
- RTS
5 L% D2 s! F1 o& v+ W - % {+ I/ R# G5 h. \
- BULLET_NUM: ;子弹数目
1 \( {8 h) g% p: X' @ - LDA pause ;暂停状态判断2 `+ {3 e9 ^# ~0 ~' m
- BEQ BULRTS" c4 x' N: \0 n' g+ X& v
- CPX #$00 ;主机玩家判断8 X& _4 c' I2 n& O* [2 J
- BNE BULRTS" V! [. v6 H% X$ |9 b% X
- LDA $04,X ;主机玩家判断
9 F5 |& ^+ _' S) c/ h - AND #$80 ;按键A比较5 A P" O* v3 ~
- BEQ BULRTS( z( X. S$ i8 i" _4 D3 Q" Z
- LDA $87 ;状态判断
( M2 ~( T, C& |. ~: o) S: W1 M - BEQ BUL_2
1 `, F* X1 F# P3 C2 B - BUL_1:
" \+ `6 g% J9 G# Z1 R7 S - LDA #$00
: u4 f9 P n7 X9 u2 F( \ [5 D - STA $87 ;1发子弹
6 q, _$ j1 G7 L; F' |2 K8 v. N - BEQ BULRTS% D4 }" [% U" {2 l
- BUL_2:
- _- t8 ]9 _5 {1 C/ \ - LDA #$01% C) ^; b1 J1 P" |6 [# D- _- g% F
- STA $87 ;2发子弹' A( q U: C2 z3 F2 _: i$ P
-
/ V& m3 K# X! k, x- t6 k7 x0 x - BULRTS:8 e1 H- V$ E& h: r
- RTS
( H. ^7 ^! j+ P9 _4 V' S - . g5 R4 l }# E! O3 h7 N' Q
- % Y8 D/ n9 a) v4 W
- BULLET:
; K& X: _2 }9 J - LDA pause ;判断暂停状态( w1 y' O$ X) X0 P$ z' v
- BEQ BULLETRTS
q; H4 l L2 x: ?% w - LDA $04,X9 O2 T/ n/ v% V Q( \
- CMP #$40 ;按键B比较
2 q6 I" l" w7 V i% [% b" Q$ m, e% t" M - BNE BULLETRTS
% d X/ [! X. q. L7 d$ E* ? - LDA $6002,X ;读取副武器) J" \0 _: m3 V1 O
- CMP #$03, L8 p9 Z9 j6 B( }2 d# M" t8 W
- BCC BULLETADD
6 l( o8 y, x/ z: ^; ^* N6 v - LDA #$FF6 t& c' f" i5 X% Q! s
- STA $6002,X
k* t3 ]/ D# S* ~" F - BULLETADD:+ {$ t6 c9 N7 _6 Y' w
- INC $6002,X' S7 z4 }7 B( b: c
- # z6 X2 O- ?. Z5 C
- BULLETRTS:, p* N* n; n; N
- LDA $6002,X
. x3 A+ N# ~* h1 h0 v - TAY
L+ r4 H4 p8 c% O - LDA BULLET_DATA,Y' y) @6 D: |' s, _
- STA $6004,X ;写入副武器数据2 c0 m3 x _0 z- T* L
- RTS
3 T7 [ L. @0 s0 h @! ` -
# _* H ?+ F' v" q/ A -
; O* K5 f& j1 F5 H$ F& d* M$ Y - BULLET_DATA:: Z5 _. l4 `& T( p
- .BYTE $06,$02,$03,$043 q! a( K" z3 g0 ?, c3 c- i5 J
- ) f+ c. W) U$ H0 M
-
$ ?+ n; u7 K2 F% [' B& T& |' d -
p- |+ [; o: J# |, @ - KEY_OPERATE: ;按键开关操作! L- F' t4 ]5 E. C
- data_protect: ;数据保护
/ ]8 T! N: N V% }" Q - PHA
: {" I2 u) ]# C! x( R$ f) s - TXA
% Q# S4 Q; J; i$ p - PHA' d H0 O; V' d; D; X' U0 V
- TYA* o- Z8 i! S4 P, W5 D
- PHA
$ ?. |6 K# f6 Q6 g& @. X& X - 4 }, q$ B0 b7 Q6 U' l6 n' k4 f
- FLAG_INI: ;开关标志初始化: Y- z3 x' x9 C4 s4 H8 L/ C# ^
/ Z: i9 r( M0 H# W- LDA $600F; w& L9 n6 j3 ]) Q0 U/ f7 ^
- CMP #$01
0 G' a9 G1 D( m/ f% f - BEQ pause_cmp4 ]& b( o0 X( b' l
- LDA #$003 v, G0 w6 u! {! o
- STA $6000
4 w" x4 E$ _* \5 j+ |% |; p - STA $6001
" O) x4 B& n" ^4 D a# G - STA $6002
2 i( E* y8 H! o, I/ I, V5 a - STA $6003% J" m# }$ J8 ^2 y
- STA $6004) t# {& D# v, N. `
- STA $6005" P( j4 t( P0 [* S
- LDA #$01
" ^- c* D# [1 Y. z+ J - STA $600F
/ R3 n1 A6 A, k4 F - 2 n6 H9 r( a7 n
- pause_cmp: ;判断暂停状态
2 \2 w$ V2 `: F& e4 ^ - LDA pause
# m1 ]) Q; r+ s - CMP #$01 ;判断暂停状态
; Z; w3 b. o! z" I1 _6 A - BEQ button_press; p: Z- W( d: ?. [6 f: P6 F
- PLA, D# p% p3 f/ b( o$ s3 {* d
- TAY
7 A8 N$ J3 X7 Q8 _ - PLA$ s2 m t: r3 _! s, m
- TAX
4 {# H' i3 h- \& ^3 H$ ^ - PLA
- ?5 M; e7 x3 |- g8 ?: s" _2 H' \ - RTS
5 `! p. N; D- H
) z1 C( D* q! D8 W. m* D# r- button_press: ;按压操作. W' s& ^' M7 M, l
- ini_Y:
! Y/ ]/ {. o7 d d - LDY #$007 R: t1 J5 f h: i- e: E$ w$ _
- button_cmp:) P9 B- W3 D* j: |& F
- LDA button,X! ~$ X4 l" G1 |% E2 q
- CMP ora_data,Y8 K8 A. _; Z4 f7 s3 b, c' x8 i- k
- BNE count_Y_cmp5 |8 o5 Q1 P5 \& ^
- flag_cmp:$ n% p$ |- I2 [) N* D
- LDA flag,X- p8 F& b, \0 C, V
- AND ora_data,Y R: D$ h( F4 B) ?; [
- BNE flag_and
" r/ ]6 Y1 b# ^ - flag_ora:
3 ]& r4 S, O: I0 E, f4 J - LDA flag,X4 u5 [, a. @" N/ P
- ORA ora_data,Y6 j" l4 R) D7 Z
- STA flag,X
. u" B* _2 Y) y - BNE count_Y_cmp! u" _7 p& K; e/ Y5 X$ n. Y$ S
- flag_and:5 g. y* u+ R( \' }) @
- LDA flag,X
1 V9 V8 m8 }. m2 Q. U - AND and_data,Y
* f9 S/ Y) p3 ^) _ - STA flag,X% v0 N9 T: X" K# C
- count_Y_cmp:
( V7 G& k5 n" s: f4 Z; W - INY
( C5 c' O* S- J( Z3 D! h' Q - CPY #$08( C3 A/ V2 ]% V1 z
- BCC button_cmp
8 g6 l3 k6 E' U: V0 ~4 K -
' d0 d; J& [0 O - data_extract: ;数据恢复8 _" E0 M% y% k0 A5 \9 \; S( b( N
- PLA
+ ?$ |! S, ]) m - TAY b) @' |. x) M( o
- PLA( o& ~! f- F! I7 W0 \ G' _
- TAX* J! j3 C3 P) ~4 ?, I
- PLA a# [- \ e- T* L
- `& v+ p5 ^8 | y0 [
- return:
; e0 U$ g+ R9 f- B$ J - RTS
s6 u0 A4 Z$ l9 K W5 w -
; R, J/ o) p' x# L/ k - ora_data: ;按键相或数据
& l; a6 _* Q5 c+ S1 P7 y# D - .BYTE $08,$04,$02,$01,$80,$40,$20,$104 K/ g" T/ P) d$ I4 c
- and_data: ;按键相与数据 P! Z6 x3 \) p, D* G7 G, p
- .BYTE $F7,$FB,$FD,$FE,$7F,$BF,$DF,$EF% z. D! S9 v1 x& ~' |# K' z7 ?
-
" @' p& P2 R! X2 P -
4 r1 v" h: J9 S; \) ~5 B -
1 F6 j8 O& @" ^4 w -
$ {6 O' h* I, v/ c% U -
$ S) y7 U! }( Z( N4 m - 4 T( Y" p% N8 h! L3 y4 J% S- C
( j% x1 U- B7 ^- ~: F- 4 A" V: y* W( m+ p) p$ I& C
& G7 f# R. B, g! e+ s- .ORG $C264 ;自定义的MAPPER2切页程序" X1 E! \2 t7 E: [
- PHA" i* {& k- E. q1 F" {
- TXA
5 I' }, M. e+ B( h7 v8 I - PHA: t( [4 x* U# x% \
- LDA $0066- f8 _, T) j( w" D
- BNE ADDRC280' |6 b% C8 g! u+ x- j* n
- LDA #$07/ O+ V9 c! J3 e/ Y4 q* U
- LDX #$03( L2 M$ k. z# Q' q7 m$ x
- JSR $CD9B ;自带的切bank方法, q! E$ @' M7 s9 ^, ~& v
- PLA
* z5 [1 u _5 [) B0 O - TAX
$ t, r; M- v2 v4 S$ s - PLA
0 F/ @! x' @; j* Y" z7 p - JSR $8000
6 `, H: D% }8 u4 N. G& ^. `% l" q - LDA #$067 ?: b% F) k6 q7 e" V7 B6 }/ I. Z
- LDX #$03
7 ?6 U( \) j$ z- T - JSR $CD9B ;切回原该切得bank(可以不用)
, |9 V" r/ v; M" W) I/ R N - RTS
+ w p) Q7 o) c% x m8 } - ADDRC280:
& y. v% E4 u8 E5 A+ W3 j - PLA+ v( s8 i @7 w' Y" L4 C( C- U
- TAX, _; r4 ]6 E) K M6 P9 l/ G
- PLA
, s8 a- D; r1 l2 t, e7 K - RTS
j6 H8 R! R, ?: B. G' S -
( e! \& S' y7 N7 T* V - 9 ^: S( ^8 U3 y6 E+ R
- ;[FC][最终任务PPU][END]
, R! \5 f! u: n- n1 M - .ORG $C056 ;跳转到PPU重写程序
' K4 d( a$ n5 n8 i5 B; C - JSR $7000
3 `7 a4 u6 m" I( H$ I8 N( i% J4 Y
5 H6 f; J6 y2 s l0 q- .ORG $CEBF
8 N+ F$ Z0 h, ?5 W! X' C. P8 L - JSR STAGE_DATA_WRITE ;跳转到关卡数据写入
4 e. x' i- K5 p' {5 l -
' \; E; n% l. J, l - .ORG $E460
# V8 a$ v& E, T b - JSR BULLET_DATA_WRITE ;跳转到副武器数据写入! [7 A/ t4 v0 B) l, O9 x( d/ M
- ?$ C/ m n' z
- .ORG $71F05 [! \/ B0 G( ?) T- R4 h
- STAGE_DATA_WRITE:. j3 j( z/ Q$ k$ c T
- LDA $6010
) m, W$ g* ?& V4 C - STA $1E ;关卡写入
K6 V0 y A& w8 \$ x - LDA #$00
- \0 ?) ^9 j& b - RTS
, J4 q8 v/ Y8 Y7 a d- ~ - .ORG $71C0( B& ^/ Y4 u; e; ^' }* y! q
- BULLET_DATA_WRITE: ;副武器数据写入
2 W9 m# Q9 n- W: S, I! M: A - CPX #$0E T, E1 q. m: G9 q# r+ T
- BCS P2_BUL( W! `, \: V+ \( J) m3 d% H
- P1_BUL:
# i0 G. y2 f% T; V - LDA $6004
7 f O# F- d& I/ C8 d9 d - JSR $D7D0 ;P1副武器数据写入
8 f4 j! r8 L7 R2 Q/ O s - RTS6 f, l6 d" K# V% W- f
- P2_BUL:
% B0 `- [) L/ ^' n" w+ w5 M - LDA $60050 D+ P% U! k% y3 A' P. U% i
- JSR $D7D0 ;P2副武器数据写入
- v6 N6 _& Z+ C, @/ C) e8 `8 J - RTS
5 X# [/ I9 E/ A, O9 N1 W( @# @
1 M; b; r7 F& o4 b2 L' _
. d: y4 l! ^. u: {* Q c- .ORG $7000
! b0 s1 R( o+ F8 R, Y* v) F -
" g% U- _) W# p% Q4 \ - STY $4014 ;补上覆盖的精灵写入指令
! y) x& ^- B+ K; H3 P - PHA0 G# f' q" f8 q; e: _
- TXA f6 G, h9 E: c& v
- PHA4 j; q& P, g5 c. o* ]* |2 s
- TYA
9 ?7 @9 B3 O0 I1 i3 { - PHA4 m& p! |* B8 P/ }6 g
- LDA $0C
6 b- ~) g6 D/ C) ] - CMP #$01 ;比较是否为标题画面
. m c$ k3 i& D+ Y; _( S - BEQ PPU_STAGE7 f4 M" l: g" {9 Y! a: s& t8 G4 u
- PLA/ j: i3 W# `, u! n
- TAY; V2 e! ] `- o( `
- PLA
) c V; w, W4 {! C6 ?) s - TAX7 w0 Q- [4 ?4 z% e, T; v
- PLA/ y2 H% Y4 z! U' ~* [8 M3 q
- RTS, R: F# n8 H, Y, b, j9 [ j
- PPU_STAGE: ;STAGE显示程序7 Z! L3 b' b. p6 ^; `
- LDA PPU_ADDR_DATA
% [) K, {& v( M) K$ {8 g. ^ - STA $2006
: U0 V2 A! `+ K3 R4 R - LDA PPU_ADDR_DATA+13 W: S9 \. f- J/ e' b
- STA $2006 ;坐标设置- e6 `- z" C5 G4 ?6 F6 |
- LDX #$00. ~+ b7 V& p, e- k1 b5 m
- PPU_STAGE_WROTE: ;写入STAGE字模- V: b C( K0 ^( Y2 `
- LDA STAGE_DATA,X
, N' V$ j7 M# ]: L - STA $2007( k" z* _% r. q1 q( q; |" r
- INX
! U4 t6 q( Q3 X2 U, r - CPX #$06! F1 J/ W8 k4 E/ i6 N6 e- n
- BCC PPU_STAGE_WROTE
, ^, J5 _* c' z' A - LDA $6010
( P! `$ [* \* D; l8 x - CMP #$FF ;关卡数据初始化条件判断* \5 @7 Z+ T5 a3 d* t: H+ c' o
- BNE KEY_B& H4 F/ Y: h7 T0 K
- LDA #$00
' i4 H, j( {! H$ E4 t: @ - STA $6010 ;关卡数据初始化
" L8 L4 m8 E1 V5 j2 ] - KEY_B: ;关卡减少
* u6 D9 w' U: B7 ~1 G3 \( [ - LDA $04
0 e3 r9 `+ R8 J( c Q) F/ a - AND #$42 ;按键B或左减关
7 i% n: F. y3 a - BEQ KEY_A5 Y! ~4 ~. E# n( Z( E1 T( F% [
- LDA $6010/ \7 F7 l( j6 g3 v( a( f) d
- CMP #$00 ;关卡比较
$ I. i: ^8 M) S - BEQ KEY_A
: z8 C% ^) m5 Z+ g, h+ M- r! w3 B - DEC $6010 ;减关% X9 b) J4 J% ?5 U; ?( Y9 M0 Y! e0 F
- KEY_A: ;关卡增加
/ g+ Q) H! G! J( T1 a6 ?6 m0 ^4 E8 @# P - LDA $04
) L- b) I( o( R: d - AND #$81 ;按键A或右加关2 Z. T0 e7 a& J! _$ o9 n
- BEQ PPU_NUM_WRITE
/ z2 @: i: O. n; m% ` - LDA $6010( Z0 b3 ~( W2 }
- CMP #$04 ;关卡比较 |0 a2 Q% U2 o; Y+ z; J
- BEQ PPU_NUM_WRITE
3 c- n( Q- D, E: ?# L - INC $6010 ;加关
) Q" w5 p+ C$ b9 L% E( w - PPU_NUM_WRITE:$ N J0 {2 _) v+ w
- LDA $6010
- f6 ]1 q3 h, X( M2 l - TAX; e2 f4 ]8 \& N7 G& B8 P' z- Q
- LDA STAGE_NUM,X ;写入数字
; B# _2 h0 K/ B# a) m/ K1 |+ e - STA $20073 e& Y- s: O5 [
- PPU_RTS:
- N ~) W' b% T - PLA
% i% z, C+ L6 ~+ U) z8 g - TAY
, S1 ?' N3 T3 S$ B# d; a - PLA
0 X9 b* ^. P, b g - TAX" R3 H" b5 U8 f, G, ~( G: _
- PLA
( m+ y( C s1 n- r - RTS
' f. R& r" J5 g* Y4 M3 J - 5 O+ C0 f1 |" f) C
- 1 Z" k; Q F- T
- STAGE_DATA: ;关卡文字S,T,A,G,E,字模数据
) |+ e N1 @* N7 Z. q1 E1 o+ R" }$ j - .BYTE $EC,$ED,$DA,$E0,$DE,009 `5 \ Y+ t Z1 u
- STAGE_NUM: ;关卡数字1,2,3,4,5字模数据# z* X+ d* ]( `1 n3 y9 I
- .BYTE $D1,$D2,$D3,$D4,$D5
% m. g9 D( L2 w. K# g. y" q -
/ e7 P3 @8 ^3 K6 Y - PPU_ADDR_DATA:( D, q, m# g# |6 n1 Z
- .BYTE $23,$0C; V! X6 K% E. ^. _
-
5 B$ s9 [2 E! l% g0 O
复制代码 |
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有账号?立即注册
x
评分
-
1
查看全部评分
-
|