-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcrash.a
69 lines (68 loc) · 848 Bytes
/
crash.a
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
!zone {
lda CRASH
bne .nocrash
lda CXP0FB
ora CXP1FB
and #$80
beq .nocrash
lda #8
sta AUDC1
lda #0
sta AUDV0
sta AUDC0
lda #$80
sta CRASH
lda #$3f
sta EXPLOSION
lda #0
sta SPEEDY0_LO
sta SPEEDY0_HI
sta SPEEDY1_LO
sta SPEEDY1_HI
sta SPEEDX0_LO
sta SPEEDX0_HI
sta SPEEDX1_LO
sta SPEEDX1_HI
lda CXP0FB
and #$80
beq .nocrashp0
dec P0LIVES
.nowinnerp0
lda #120
sta Y0_HI
lda P0LIVES
bne .nocrashp0
lda #1
sta RESET
.nocrashp0
lda CXP1FB
and #$80
beq .nocrashp1
dec P1LIVES
.nowinnerp1
lda #120
sta Y1_HI
lda P1LIVES
bne .nocrashp1
lda #1
sta RESET
.nocrashp1
lda P0LIVES
ora P1LIVES
bne .notboth
lda #$50
sta WINNER_COLOR
jmp .nocrash
.notboth
lda P0LIVES
bne .checknext
lda #P1COL-10
sta WINNER_COLOR
jmp .nocrash
.checknext
lda P1LIVES
bne .nocrash
lda #P0COL-10
sta WINNER_COLOR
.nocrash
}