peasant: hook up points for hitting top of cliff

This commit is contained in:
Vince Weaver 2024-10-08 00:16:34 -04:00
parent b3548c4071
commit 3b314fa727
3 changed files with 59 additions and 20 deletions

View File

@ -44,19 +44,6 @@ cliff_heights:
jsr update_score
; FIXME!
; only set this if just arrived, not if loading saved game
lda #14
sta PEASANT_X
lda #150
sta PEASANT_Y
lda #0
sta PEASANT_XADD
sta PEASANT_YADD
;=============================
;=============================
; new screen location
@ -179,6 +166,54 @@ col_copy_loop:
jsr zx02_full_decomp
lda GAME_STATE_3
and #CLIFF_CLIMBED
bne cliff_already_climbed
; only set this if just arrived, not if loading saved game
lda #14
sta PEASANT_X
lda #150
sta PEASANT_Y
lda #0
sta PEASANT_XADD
sta PEASANT_YADD
; ldx #<gary_scare_message
; ldy #>gary_scare_message
; jsr partial_message_step
; score points
lda #3
jsr score_points
lda GAME_STATE_3
ora #CLIFF_CLIMBED
sta GAME_STATE_3
; TODO: break fence
ldx #<cliff_heights_top_message
ldy #>cliff_heights_top_message
stx OUTL
sty OUTH
jsr print_text_message
jsr wait_until_keypress
jsr restore_parse_message
cliff_already_climbed:
;===========================
;===========================
;===========================
@ -338,6 +373,7 @@ exiting_cliff:
.include "../version.inc"
;.include "../print_text_message.s"
.include "graphics_heights/cliff_heights_graphics.inc"
.include "graphics_heights/priority_cliff_heights.inc"

View File

@ -7,6 +7,7 @@
; lightning makes sound effect, same as rock crashing noise
; shows once atop
cliff_heights_top_message:
.byte "Nice jorb climbing the",13
.byte "cliff. You have a real way",13
.byte "with those arrow keys.",0

View File

@ -159,12 +159,9 @@ PEASANT_DIR = $93
PEASANT_DIR_LEFT = 2
PEASANT_DIR_DOWN = 3
GAME_STATE_3 = $94
; SWORD_THROWN = $01
MAP_LOCATION = $94
MAP_LOCATION = $96
GAME_STATE_0 = $97
GAME_STATE_0 = $96
BABY_IN_WELL=$01
BUCKET_DOWN_WELL=$02
TALKED_TO_MENDELEV=$04
@ -173,7 +170,7 @@ GAME_STATE_0 = $97
GARY_SCARED=$20
LADY_GONE=$40
TRINKET_GIVEN=$80
GAME_STATE_1 = $98
GAME_STATE_1 = $97
FISH_FED=$01 ; also implies man gone and inn open
PUDDLE_WET=$02
IN_HAY_BALE=$04
@ -182,7 +179,7 @@ GAME_STATE_1 = $98
NIGHT=$20
POT_ON_HEAD=$40
WEARING_ROBE=$80
GAME_STATE_2 = $99
GAME_STATE_2 = $98
ON_FIRE = $01
COTTAGE_ROCK_MOVED=$02
KNUCKLES_BLEED=$04
@ -192,6 +189,11 @@ GAME_STATE_2 = $99
GOT_MUDDY_ALREADY = $40
GREASE_ON_HEAD =$80
GAME_STATE_3 = $99
; SWORD_THROWN = $01
CLIFF_CLIMBED = $02
NED_STATUS = $9A
; 0 = hiding (no increment)
; 1..127 = count up to appearing