mirror of
https://github.com/deater/dos33fsprogs.git
synced 2024-12-29 00:31:52 +00:00
keen: implement game over
This commit is contained in:
parent
9f7eda8d8a
commit
4f8168a01d
@ -50,7 +50,7 @@ keen_title.o: keen_title.s zp.inc hardware.inc \
|
||||
KEEN_MARS: keen_mars.o
|
||||
ld65 -o KEEN_MARS keen_mars.o -C ../../linker_scripts/apple2_2000.inc
|
||||
|
||||
keen_mars.o: keen_mars.s zp.inc hardware.inc \
|
||||
keen_mars.o: keen_mars.s zp.inc hardware.inc game_over.s \
|
||||
sound_effects.s speaker_tone.s print_help.s \
|
||||
maps/mars_map.gr.zx02 graphics/parts.gr.zx02
|
||||
ca65 -o keen_mars.o keen_mars.s -l keen_mars.lst
|
||||
|
@ -6,7 +6,7 @@ lo-res version
|
||||
+ check raygun count before shooting
|
||||
+ fix background tile when get item
|
||||
+ fix keybindings/help menu
|
||||
+ play jingle entering/leaving level
|
||||
+ better start/stop level music
|
||||
+ implement leaving level
|
||||
+ animate death
|
||||
+ game over screen if out of lives
|
||||
@ -14,3 +14,13 @@ lo-res version
|
||||
hi-res version
|
||||
~~~~~~~~~~~~~~
|
||||
+
|
||||
|
||||
mars
|
||||
~~~~
|
||||
+ convert to full tilemap
|
||||
+ mark completed levels
|
||||
|
||||
title
|
||||
~~~~~
|
||||
+ actual menu?
|
||||
|
||||
|
47
games/keen/game_over.s
Normal file
47
games/keen/game_over.s
Normal file
@ -0,0 +1,47 @@
|
||||
; GAME OVER MAN
|
||||
|
||||
game_over:
|
||||
bit KEYRESET ; clear keyboard
|
||||
bit SET_TEXT
|
||||
|
||||
lda #' '|$80
|
||||
sta clear_all_color+1
|
||||
jsr clear_all
|
||||
|
||||
lda #6
|
||||
sta drawbox_x1
|
||||
lda #33
|
||||
sta drawbox_x2
|
||||
lda #8
|
||||
sta drawbox_y1
|
||||
lda #13
|
||||
sta drawbox_y2
|
||||
jsr drawbox
|
||||
|
||||
jsr normal_text
|
||||
|
||||
lda #<game_over_text
|
||||
sta OUTL
|
||||
lda #>game_over_text
|
||||
sta OUTH
|
||||
jsr move_and_print_list
|
||||
|
||||
jsr page_flip
|
||||
|
||||
query_game_over:
|
||||
lda KEYPRESS
|
||||
bpl query_game_over
|
||||
bit KEYRESET
|
||||
|
||||
really_game_over:
|
||||
lda #GAME_OVER
|
||||
sta LEVEL_OVER
|
||||
|
||||
lda #LOAD_TITLE
|
||||
sta WHICH_LOAD
|
||||
|
||||
rts
|
||||
|
||||
game_over_text:
|
||||
.byte 15,10,"GAME OVER",0
|
||||
.byte 255
|
@ -1,6 +1,6 @@
|
||||
; Keen MARS main map
|
||||
|
||||
; TODO: should make it scrollable, etc
|
||||
; TODO: should make it scrollable, etc / tilemap
|
||||
|
||||
; by deater (Vince Weaver) <vince@deater.net>
|
||||
|
||||
@ -9,7 +9,7 @@
|
||||
.include "hardware.inc"
|
||||
.include "common_defines.inc"
|
||||
|
||||
keen_start:
|
||||
mars_start:
|
||||
;===================
|
||||
; init screen
|
||||
jsr TEXT
|
||||
@ -23,6 +23,9 @@ keen_start:
|
||||
|
||||
jsr clear_all ; avoid grey stripes at load
|
||||
|
||||
lda KEENS
|
||||
bmi return_to_title
|
||||
|
||||
;=====================
|
||||
; init vars
|
||||
;=====================
|
||||
@ -126,12 +129,16 @@ do_keen_loop:
|
||||
|
||||
|
||||
done_with_keen:
|
||||
cmp #GAME_OVER
|
||||
beq return_to_title
|
||||
|
||||
; else, start level
|
||||
|
||||
bit KEYRESET ; clear keypress
|
||||
|
||||
; sound effect
|
||||
|
||||
jsr entry_music
|
||||
; jsr exit_music
|
||||
|
||||
lda #LOAD_KEEN1
|
||||
sta WHICH_LOAD
|
||||
@ -139,6 +146,18 @@ done_with_keen:
|
||||
rts ; exit back
|
||||
|
||||
|
||||
return_to_title:
|
||||
|
||||
jsr game_over
|
||||
|
||||
lda #LOAD_TITLE
|
||||
sta WHICH_LOAD
|
||||
|
||||
rts
|
||||
|
||||
|
||||
|
||||
|
||||
;==========================
|
||||
; includes
|
||||
;==========================
|
||||
@ -165,7 +184,8 @@ parts_zx02:
|
||||
.include "text_drawbox.s"
|
||||
.include "print_help.s"
|
||||
.include "quit_yn.s"
|
||||
; .include "level_end.s"
|
||||
.include "game_over.s"
|
||||
|
||||
|
||||
.include "sound_effects.s"
|
||||
.include "speaker_tone.s"
|
||||
|
Loading…
Reference in New Issue
Block a user