mist: split off D'NI to its own file
probably not necessary but gives some room in the OCTAGON file
|
@ -12,7 +12,8 @@ zip: mist.dsk mist_side2.dsk mist_side3.dsk
|
|||
zip mist.zip mist.dsk mist_side2.dsk mist_side3.dsk
|
||||
|
||||
mist.dsk: HELLO LOADER MIST_TITLE MIST OCTAGON VIEWER \
|
||||
MECHE SELENA CABIN CHANNEL STONEY DENTIST GENERATOR SAVE0
|
||||
MECHE SELENA CABIN CHANNEL STONEY DENTIST GENERATOR \
|
||||
D\'NI SAVE0
|
||||
cp empty.dsk mist.dsk
|
||||
$(DOS33) -y mist.dsk SAVE A HELLO
|
||||
$(DOS33) -y mist.dsk BSAVE -a 0x1000 LOADER
|
||||
|
@ -22,6 +23,7 @@ mist.dsk: HELLO LOADER MIST_TITLE MIST OCTAGON VIEWER \
|
|||
$(DOS33) -y mist.dsk BSAVE -a 0x2000 CABIN
|
||||
$(DOS33) -y mist.dsk BSAVE -a 0x2000 DENTIST
|
||||
$(DOS33) -y mist.dsk BSAVE -a 0x2000 GENERATOR
|
||||
$(DOS33) -y mist.dsk BSAVE -a 0x2000 D\'NI
|
||||
$(DOS33) -y mist.dsk BSAVE -a 0xe00 SAVE0
|
||||
$(DOS33) -y mist.dsk BSAVE -a 0x9000 ./audio/link_noise.btc LINK_NOISE.BTC
|
||||
|
||||
|
@ -142,19 +144,25 @@ octagon.o: octagon.s zp.inc hardware.inc common_defines.inc \
|
|||
books/octagon_books.inc \
|
||||
common_sprites.inc page_sprites.inc \
|
||||
leveldata_octagon.inc \
|
||||
letter_cat.s \
|
||||
marker_switch.s \
|
||||
brother_books.s \
|
||||
keyboard.s \
|
||||
draw_pointer.s \
|
||||
end_level.s \
|
||||
handle_pages.s \
|
||||
octagon_bookshelf.s \
|
||||
octagon_rotation.s \
|
||||
octagon_fireplace.s \
|
||||
gr_copy.s audio.s text_print.s decompress_fast_v2.s
|
||||
octagon_fireplace.s
|
||||
ca65 -o octagon.o octagon.s -l octagon.lst
|
||||
|
||||
####
|
||||
|
||||
D\'NI: dni.o
|
||||
ld65 -o D\'NI dni.o -C ../linker_scripts/apple2_2000.inc
|
||||
|
||||
dni.o: dni.s zp.inc hardware.inc common_defines.inc \
|
||||
common_routines.inc \
|
||||
graphics_dni/dni_graphics.inc \
|
||||
leveldata_dni.inc
|
||||
ca65 -o dni.o dni.s -l dni.lst
|
||||
|
||||
|
||||
|
||||
####
|
||||
|
||||
|
@ -351,6 +359,9 @@ graphics_arbor/arbor_graphics.inc:
|
|||
graphics_nibel/nibel_graphics.inc:
|
||||
cd graphics_nibel && make
|
||||
|
||||
graphics_dni/dni_graphics.inc:
|
||||
cd graphics_dni && make
|
||||
|
||||
|
||||
####
|
||||
|
||||
|
|
|
@ -50,7 +50,7 @@ LOAD_ARBOR = 10
|
|||
LOAD_NIBEL = 11
|
||||
LOAD_SHIP = 12
|
||||
LOAD_GENERATOR = 13
|
||||
LOAD_ENDING = 14
|
||||
LOAD_DNI = 14
|
||||
|
||||
;================================
|
||||
; Level definitions
|
||||
|
@ -153,9 +153,6 @@ OCTAGON_IN_FIREPLACE_CLOSED = 34
|
|||
OCTAGON_FIREPLACE_SHELF = 35
|
||||
OCTAGON_GREEN_BOOK = 36
|
||||
OCTAGON_GREEN_BOOK_OPEN = 37
|
||||
OCTAGON_DNI = 38
|
||||
OCTAGON_DNI_DESK = 39
|
||||
|
||||
|
||||
; Mechanical Engineering
|
||||
|
||||
|
@ -434,3 +431,6 @@ DENTIST_CHAIR_CLOSE = 3
|
|||
DENTIST_PANEL_UP = 4
|
||||
DENTIST_PANEL = 5
|
||||
|
||||
DNI_ARRIVAL = 0
|
||||
DNI_DESK = 1
|
||||
|
||||
|
|
|
@ -5,51 +5,51 @@
|
|||
opendir_filename =$1039
|
||||
|
||||
; audio.c
|
||||
play_audio =$1350
|
||||
play_audio =$134e
|
||||
|
||||
; decompress_fast_v2.s
|
||||
decompress_lzsa2_fast =$1461
|
||||
getsrc_smc =$1557
|
||||
decompress_lzsa2_fast =$145f
|
||||
getsrc_smc =$1555
|
||||
|
||||
; draw_pointer.s
|
||||
draw_pointer =$1564
|
||||
draw_pointer =$1562
|
||||
|
||||
; end_level.s
|
||||
end_level =$16a7
|
||||
end_level =$16a5
|
||||
|
||||
; gr_copy.s
|
||||
gr_copy_to_current =$16c9
|
||||
gr_copy_to_current =$16c7
|
||||
|
||||
; gr_fast_clear.s
|
||||
clear_bottom =$17ef
|
||||
clear_all =$182d
|
||||
clear_all_color =$1852
|
||||
clear_bottom =$17ed
|
||||
clear_all =$182b
|
||||
clear_all_color =$1850
|
||||
|
||||
; gr_offsets.s
|
||||
gr_offsets =$1870
|
||||
gr_offsets =$186e
|
||||
|
||||
; gr_page_flip.s
|
||||
page_flip =$18a0
|
||||
page_flip =$189e
|
||||
|
||||
; gr_putsprite_crop.s
|
||||
put_sprite_crop =$18ba
|
||||
psc_smc1 =$18dd
|
||||
psc_smc2 =$1975
|
||||
put_sprite_crop =$18b8
|
||||
psc_smc1 =$18db
|
||||
psc_smc2 =$1973
|
||||
|
||||
; keyboard.s
|
||||
handle_keypress =$19f6
|
||||
change_location =$1ad7
|
||||
handle_keypress =$19f4
|
||||
change_location =$1ad5
|
||||
|
||||
; text_print.s
|
||||
move_and_print =$1b6f
|
||||
ps_smc1 =$1b9c
|
||||
move_and_print =$1b6d
|
||||
ps_smc1 =$1b9a
|
||||
|
||||
; page_sprites.inc
|
||||
blue_page_sprite =$1c84
|
||||
red_page_sprite =$1c9a
|
||||
white_page_sprite =$1cb0
|
||||
blue_page_small_sprite =$1cc6
|
||||
red_page_small_sprite =$1cce
|
||||
blue_page_sprite =$1c82
|
||||
red_page_sprite =$1c98
|
||||
white_page_sprite =$1cae
|
||||
blue_page_small_sprite =$1cc4
|
||||
red_page_small_sprite =$1ccc
|
||||
|
||||
; audio files
|
||||
linking_noise = $9000
|
||||
|
|
|
@ -0,0 +1,147 @@
|
|||
; D'NI -- deep beneath New Mexico
|
||||
|
||||
; by deater (Vince Weaver) <vince@deater.net>
|
||||
|
||||
; Zero Page
|
||||
.include "zp.inc"
|
||||
.include "hardware.inc"
|
||||
.include "common_defines.inc"
|
||||
.include "common_routines.inc"
|
||||
|
||||
dni_start:
|
||||
;===================
|
||||
; init screen
|
||||
jsr TEXT
|
||||
jsr HOME
|
||||
bit KEYRESET
|
||||
|
||||
bit SET_GR
|
||||
bit PAGE0
|
||||
bit LORES
|
||||
bit FULLGR
|
||||
|
||||
;=================
|
||||
; set up location
|
||||
;=================
|
||||
|
||||
lda #<locations
|
||||
sta LOCATIONS_L
|
||||
lda #>locations
|
||||
sta LOCATIONS_H
|
||||
|
||||
lda #0
|
||||
sta DRAW_PAGE
|
||||
sta LEVEL_OVER
|
||||
sta ANIMATE_FRAME
|
||||
|
||||
; init cursor
|
||||
|
||||
lda #20
|
||||
sta CURSOR_X
|
||||
sta CURSOR_Y
|
||||
|
||||
|
||||
; set up initial location
|
||||
|
||||
jsr change_location
|
||||
|
||||
lda #1
|
||||
sta CURSOR_VISIBLE ; visible at first
|
||||
|
||||
|
||||
|
||||
game_loop:
|
||||
;=================
|
||||
; reset things
|
||||
;=================
|
||||
|
||||
lda #0
|
||||
sta IN_SPECIAL
|
||||
sta IN_RIGHT
|
||||
sta IN_LEFT
|
||||
|
||||
;====================================
|
||||
; copy background to current page
|
||||
;====================================
|
||||
|
||||
jsr gr_copy_to_current
|
||||
|
||||
;====================================
|
||||
; handle special-case forground logic
|
||||
;====================================
|
||||
|
||||
; things always happening
|
||||
lda LOCATION
|
||||
|
||||
done_foreground:
|
||||
;====================================
|
||||
; handle animations
|
||||
;====================================
|
||||
|
||||
; things only happening when animating
|
||||
|
||||
lda ANIMATE_FRAME
|
||||
beq nothing_special
|
||||
|
||||
lda LOCATION
|
||||
|
||||
nothing_special:
|
||||
|
||||
;====================================
|
||||
; draw pointer
|
||||
;====================================
|
||||
|
||||
jsr draw_pointer
|
||||
|
||||
;====================================
|
||||
; page flip
|
||||
;====================================
|
||||
|
||||
jsr page_flip
|
||||
|
||||
;====================================
|
||||
; handle keypress/joystick
|
||||
;====================================
|
||||
|
||||
jsr handle_keypress
|
||||
|
||||
|
||||
;====================================
|
||||
; inc frame count
|
||||
;====================================
|
||||
|
||||
inc FRAMEL
|
||||
bne room_frame_no_oflo
|
||||
inc FRAMEH
|
||||
room_frame_no_oflo:
|
||||
|
||||
;====================================
|
||||
; check level over
|
||||
;====================================
|
||||
|
||||
lda LEVEL_OVER
|
||||
bne really_exit
|
||||
jmp game_loop
|
||||
|
||||
really_exit:
|
||||
jmp end_level
|
||||
|
||||
|
||||
|
||||
;==========================
|
||||
; includes
|
||||
;==========================
|
||||
|
||||
; level graphics
|
||||
.include "graphics_dni/dni_graphics.inc"
|
||||
|
||||
; puzzles
|
||||
|
||||
; linking books
|
||||
|
||||
; books
|
||||
|
||||
; level data
|
||||
.include "leveldata_dni.inc"
|
||||
|
||||
|
|
@ -0,0 +1,31 @@
|
|||
#include ../Makefile.inc
|
||||
|
||||
PNG2RLE = ../../gr-utils/png2rle
|
||||
PNG2GR = ../../gr-utils/png2gr
|
||||
LZSA = ~/research/lzsa/lzsa/lzsa
|
||||
|
||||
all: dni_graphics.inc
|
||||
|
||||
|
||||
####
|
||||
|
||||
dni_graphics.inc: \
|
||||
dni_n.lzsa dni_s.lzsa dni_e.lzsa dni_w.lzsa \
|
||||
dni_desk_n.lzsa dni_desk_s.lzsa
|
||||
echo "dni_n_lzsa: .incbin \"dni_n.lzsa\"" > dni_graphics.inc
|
||||
echo "dni_s_lzsa: .incbin \"dni_s.lzsa\"" >> dni_graphics.inc
|
||||
echo "dni_e_lzsa: .incbin \"dni_e.lzsa\"" >> dni_graphics.inc
|
||||
echo "dni_w_lzsa: .incbin \"dni_w.lzsa\"" >> dni_graphics.inc
|
||||
echo "dni_desk_n_lzsa: .incbin \"dni_desk_n.lzsa\"" >> dni_graphics.inc
|
||||
echo "dni_desk_s_lzsa: .incbin \"dni_desk_s.lzsa\"" >> dni_graphics.inc
|
||||
|
||||
%.gr: %.png
|
||||
$(PNG2GR) $< $@
|
||||
|
||||
%.lzsa: %.gr
|
||||
$(LZSA) -r -f2 $< $@
|
||||
|
||||
####
|
||||
|
||||
clean:
|
||||
rm -f *~ *.o *.lst *.gr *.lzsa dni_graphics.inc
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
Before Width: | Height: | Size: 970 B After Width: | Height: | Size: 970 B |
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
|
@ -51,9 +51,7 @@ octagon_graphics.inc: \
|
|||
elevator_dark_s.lzsa \
|
||||
red_book_ending.lzsa blue_book_ending.lzsa \
|
||||
fireplace_shelf.lzsa \
|
||||
green_book.lzsa green_book_open.lzsa \
|
||||
dni_n.lzsa dni_s.lzsa dni_e.lzsa dni_w.lzsa \
|
||||
dni_desk_n.lzsa dni_desk_s.lzsa
|
||||
green_book.lzsa green_book_open.lzsa
|
||||
echo "temple_door_n_lzsa: .incbin \"temple_door_n.lzsa\"" > octagon_graphics.inc
|
||||
echo "temple_door_s_lzsa: .incbin \"temple_door_s.lzsa\"" >> octagon_graphics.inc
|
||||
echo "temple_door_closed_s_lzsa: .incbin \"temple_door_closed_s.lzsa\"" >> octagon_graphics.inc
|
||||
|
@ -128,12 +126,6 @@ octagon_graphics.inc: \
|
|||
echo "fireplace_shelf_lzsa: .incbin \"fireplace_shelf.lzsa\"" >> octagon_graphics.inc
|
||||
echo "green_book_lzsa: .incbin \"green_book.lzsa\"" >> octagon_graphics.inc
|
||||
echo "green_book_open_lzsa: .incbin \"green_book_open.lzsa\"" >> octagon_graphics.inc
|
||||
echo "dni_n_lzsa: .incbin \"dni_n.lzsa\"" >> octagon_graphics.inc
|
||||
echo "dni_s_lzsa: .incbin \"dni_s.lzsa\"" >> octagon_graphics.inc
|
||||
echo "dni_e_lzsa: .incbin \"dni_e.lzsa\"" >> octagon_graphics.inc
|
||||
echo "dni_w_lzsa: .incbin \"dni_w.lzsa\"" >> octagon_graphics.inc
|
||||
echo "dni_desk_n_lzsa: .incbin \"dni_desk_n.lzsa\"" >> octagon_graphics.inc
|
||||
echo "dni_desk_s_lzsa: .incbin \"dni_desk_s.lzsa\"" >> octagon_graphics.inc
|
||||
|
||||
%.gr: %.png
|
||||
$(PNG2GR) $< $@
|
||||
|
|
|
@ -0,0 +1,40 @@
|
|||
;===============================================
|
||||
; level data for D'NI
|
||||
;===============================================
|
||||
|
||||
locations:
|
||||
.word location0, location1
|
||||
|
||||
; DNI_ARRIVAL -- deep underneath New Mexico
|
||||
location0:
|
||||
.byte DNI_DESK ; north exit
|
||||
.byte $ff ; south exit
|
||||
.byte $ff ; east exit
|
||||
.byte $ff ; west exit
|
||||
.byte DIRECTION_N ; north exit_dir
|
||||
.byte $ff ; south exit_dir
|
||||
.byte $ff ; east exit_dir
|
||||
.byte $ff ; west exit_dir
|
||||
.word dni_n_lzsa ; north bg
|
||||
.word dni_s_lzsa ; south bg
|
||||
.word dni_e_lzsa ; east bg
|
||||
.word dni_w_lzsa ; west bg
|
||||
.byte BG_EAST|BG_WEST|BG_SOUTH|BG_NORTH
|
||||
.byte $ff ; special exit
|
||||
|
||||
; DNI_DESK -- Atrus' desk
|
||||
location1:
|
||||
.byte $ff ; north exit
|
||||
.byte DNI_ARRIVAL ; south exit
|
||||
.byte $ff ; east exit
|
||||
.byte $ff ; west exit
|
||||
.byte $ff ; north exit_dir
|
||||
.byte DIRECTION_E ; south exit_dir
|
||||
.byte $ff ; east exit_dir
|
||||
.byte $ff ; west exit_dir
|
||||
.word dni_desk_n_lzsa ; north bg
|
||||
.word dni_desk_s_lzsa ; south bg
|
||||
.word $0000 ; east bg
|
||||
.word $0000 ; west bg
|
||||
.byte BG_SOUTH|BG_NORTH
|
||||
.byte $ff ; special exit
|
|
@ -13,7 +13,7 @@ locations:
|
|||
.word location24,location25,location26,location27
|
||||
.word location28,location29,location30,location31
|
||||
.word location32,location33,location34,location35
|
||||
.word location36,location37,location38,location39
|
||||
.word location36,location37
|
||||
|
||||
; OCTAGON_TEMPLE_DOORWAY -- temple doorway
|
||||
location0:
|
||||
|
@ -714,36 +714,3 @@ location37:
|
|||
.byte 10,24 ; special y
|
||||
.word goto_dni-1 ; special function
|
||||
|
||||
; OCTAGON_DNI -- deep underneath New Mexico
|
||||
location38:
|
||||
.byte OCTAGON_DNI_DESK ; north exit
|
||||
.byte $ff ; south exit
|
||||
.byte $ff ; east exit
|
||||
.byte $ff ; west exit
|
||||
.byte DIRECTION_N ; north exit_dir
|
||||
.byte $ff ; south exit_dir
|
||||
.byte $ff ; east exit_dir
|
||||
.byte $ff ; west exit_dir
|
||||
.word dni_n_lzsa ; north bg
|
||||
.word dni_s_lzsa ; south bg
|
||||
.word dni_e_lzsa ; east bg
|
||||
.word dni_w_lzsa ; west bg
|
||||
.byte BG_EAST|BG_WEST|BG_SOUTH|BG_NORTH
|
||||
.byte $ff ; special exit
|
||||
|
||||
; OCTAGON_DNI_DESK -- Atrus' desk
|
||||
location39:
|
||||
.byte $ff ; north exit
|
||||
.byte OCTAGON_DNI ; south exit
|
||||
.byte $ff ; east exit
|
||||
.byte $ff ; west exit
|
||||
.byte $ff ; north exit_dir
|
||||
.byte DIRECTION_E ; south exit_dir
|
||||
.byte $ff ; east exit_dir
|
||||
.byte $ff ; west exit_dir
|
||||
.word dni_desk_n_lzsa ; north bg
|
||||
.word dni_desk_s_lzsa ; south bg
|
||||
.word $0000 ; east bg
|
||||
.word $0000 ; west bg
|
||||
.byte BG_SOUTH|BG_NORTH
|
||||
.byte $ff ; special exit
|
||||
|
|
|
@ -145,7 +145,7 @@ filenames:
|
|||
.word mist_filename,meche_filename,selena_filename,octagon_filename
|
||||
.word viewer_filename,stoney_filename,channel_filename,cabin_filename
|
||||
.word dentist_filename,arbor_filename,nibel_filename,ship_filename
|
||||
.word generator_filename,ending_filename
|
||||
.word generator_filename,dni_filename
|
||||
|
||||
intro_filename:
|
||||
.byte "MIST_TITLE",0
|
||||
|
@ -175,8 +175,8 @@ ship_filename:
|
|||
.byte "SHIP",0
|
||||
generator_filename:
|
||||
.byte "GENERATOR",0
|
||||
ending_filename:
|
||||
.byte "ENDING",0
|
||||
dni_filename:
|
||||
.byte "D'NI",0
|
||||
|
||||
|
||||
;===================================================
|
||||
|
|
|
@ -98,14 +98,19 @@ fireplace_grab_blue_page:
|
|||
|
||||
|
||||
goto_dni:
|
||||
lda #OCTAGON_DNI
|
||||
lda #DNI_ARRIVAL
|
||||
sta LOCATION
|
||||
|
||||
lda #DIRECTION_E
|
||||
sta DIRECTION
|
||||
|
||||
jmp change_location
|
||||
lda #LOAD_DNI
|
||||
sta WHICH_LOAD
|
||||
|
||||
lda #$ff
|
||||
sta LEVEL_OVER
|
||||
|
||||
rts
|
||||
|
||||
; talking to atrus
|
||||
|
||||
|
|