diff --git a/games/peasant/cliff_heights/cliff_heights.s b/games/peasant/cliff_heights/cliff_heights.s index 4d265fdc..fbf35ac7 100644 --- a/games/peasant/cliff_heights/cliff_heights.s +++ b/games/peasant/cliff_heights/cliff_heights.s @@ -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 + ; 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 + 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" diff --git a/games/peasant/text/cliff_heights.inc b/games/peasant/text/cliff_heights.inc index 1699635e..e047c1a7 100644 --- a/games/peasant/text/cliff_heights.inc +++ b/games/peasant/text/cliff_heights.inc @@ -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 diff --git a/games/peasant/zp.inc b/games/peasant/zp.inc index 8bd77f46..21134aa5 100644 --- a/games/peasant/zp.inc +++ b/games/peasant/zp.inc @@ -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