Added 6 digit score

This commit is contained in:
Rob McMullen
2017-07-21 22:26:32 -07:00
parent 152cac3ded
commit 6daefa7bfb
3 changed files with 10 additions and 7 deletions

View File

@@ -4,6 +4,7 @@ level_speed_h .byte 2, 2, 2, 2, 2, 2
;level_speed_h .byte 0, 0, 0, 0, 0, 0 ;level_speed_h .byte 0, 0, 0, 0, 0, 0
player_score_row .byte 2, 7, 12, 17 player_score_row .byte 2, 7, 12, 17
player_score_l .byte 0, 0, 0, 0 player_score_l .byte 0, 0, 0, 0
player_score_m .byte 0, 0, 0, 0
player_score_h .byte 0, 0, 0, 0 player_score_h .byte 0, 0, 0, 0
@@ -111,15 +112,17 @@ GAME_OVER = 255
; ;
;# Scores ;# Scores
; ;
DOT_SCORE = 1 DOT_SCORE = $05
PAINT_SCORE_PER_LINE = 10 box_score .byte 0, $40, $80, $120, $160, $200, $240
box_score .byte 0, $10, $20, $30, $40, $50, $60, $70, $80, $90
add_score nop add_score nop
sed sed
clc clc
adc player_score_l,x adc player_score_l,x
sta player_score_l,x sta player_score_l,x
lda player_score_m,x
adc #0
sta player_score_m,x
lda player_score_h,x lda player_score_h,x
adc #0 adc #0
sta player_score_h,x sta player_score_h,x

View File

@@ -248,7 +248,7 @@ update_score nop
sta c sta c
lda player_score_row,x lda player_score_row,x
sta r sta r
lda #4 lda #6
sta size sta size
jsr damage_string jsr damage_string
@@ -258,10 +258,10 @@ print_score nop
ldy #MAZE_SCORE_COL ldy #MAZE_SCORE_COL
lda player_score_h,x lda player_score_h,x
jsr print_hex jsr print_hex
lda player_score_m,x
jsr print_hex
lda player_score_l,x lda player_score_l,x
jsr print_hex jsr print_hex
lda #'0'
sta (mazeaddr),y
rts rts
; row = player_score_row[zp.current_actor] ; row = player_score_row[zp.current_actor]
; if actor_status[zp.current_actor] == GAME_OVER: ; if actor_status[zp.current_actor] == GAME_OVER:

2
maze.s
View File

@@ -54,7 +54,7 @@ SCREEN_ROWS = 24
MAZE_LEFT_COL = 1 MAZE_LEFT_COL = 1
MAZE_RIGHT_COL = 31 MAZE_RIGHT_COL = 31
MAZE_PANEL_COL = 33 MAZE_PANEL_COL = 33
MAZE_SCORE_COL = 35 MAZE_SCORE_COL = 34
SCREEN_COLS = 40 SCREEN_COLS = 40
;# Orbiter goes around the outside border, but not through the maze ;# Orbiter goes around the outside border, but not through the maze