mist: sub: actually hook up sub and last missing rooms

This commit is contained in:
Vince Weaver 2020-08-03 00:21:57 -04:00
parent d3e784d979
commit 9682c64710
13 changed files with 228 additions and 63 deletions

View File

@ -14,6 +14,12 @@ Compiling:
Then run "make" and hope for the best
Load times of ~8k DENTIST: MIST ~40k
DOS33: 7s TOO-BIG
PRODOS:
QKUMBA RTS: 5s 22s
TRACK-AT_TIME:
Sizes:
sectors on disk = 35*16 = 560
@ -22,31 +28,32 @@ Sizes:
======
496
disk1:
disk1: SECTORS TRACKS
HELLO 566 -> 768 -> 3
LOADER 4006 -> 4096 -> 16
MIST_TITLE 21008 -> 21248 -> 83
MIST 39780 -> 39936 -> 156
OCTAGON 32627 -> 32768 -> 128
VIEWER 4834 -> 4864 -> 19
DENTIST 7879 -> 7936 -> 31
D'NI 6863 -> 6912 -> 27
SAVE0 74 -> 256 -> 1
SHIP 5047 -> 5120 -> 20
========
484+10 = 494 = 126k
LOADER 4006 -> 4096 -> 16 1
MIST_TITLE 21008 -> 21248 -> 83 6
MIST 39780 -> 39936 -> 156 10
OCTAGON 32627 -> 32768 -> 128 8
VIEWER 4834 -> 4864 -> 19 2
DENTIST 7879 -> 7936 -> 31 2
D'NI 6863 -> 6912 -> 27 2
SAVE0 74 -> 256 -> 1 1
SHIP 5047 -> 5120 -> 20 2
======== ====
484+10 = 494 = 126k 34
disk2:
CHANNEL 34418 -> 34560 -> 135
ARBOR 31591 -> 31744 -> 124
NIBEL 15467 -> 15616 -> 61
CABIN 15398 -> 15616 -> 61
========
381+4= 385 = 98k
CHANNEL 34418 -> 34560 -> 135 9
ARBOR 31591 -> 31744 -> 124 8
NIBEL 15467 -> 15616 -> 61 4
CABIN 15398 -> 15616 -> 61 4
======== ===
381+4= 385 = 98k 25
disk3:
MECHE 28857 -> 28928 -> 113
SELENA 32902 -> 33024 -> 129
STONEY 29984 -> 30208 -> 118
GENERATOR 7456 -> 7680 -> 30
========
390+4=394 = 100k
MECHE 28857 -> 28928 -> 113 8
SELENA 36907 -> 37120 -> 145 10
STONEY 29984 -> 30208 -> 118 8
GENERATOR 8167 -> 8167 -> 2 2
SUB 8912 -> 8960 -> 35 3
======== ====
???+5=??? 31

View File

@ -270,8 +270,8 @@ SUB_INSIDE_FRONT_SELENA = 8
SUB_INSIDE_FRONT_MOVING = 9
SUB_INSIDE_FRONT_BOOK = 10
SUB_OUTSIDE_BOOK = 11
SUB_OUTSIDE_BOOK_OPEN = 12
SUB_BOOK_HALLWAY = 13
SUB_BOOK_HALLWAY = 12
SUB_BOOK_HALLWAY2 = 13
SUB_BOOK_ROOM = 14
SUB_BOOK_CLOSED = 15
SUB_BOOK_OPEN = 16

View File

@ -14,6 +14,7 @@ sub_graphics.inc: \
book_table_n.lzsa book_table_s.lzsa \
book_mist_open_s.lzsa book_mist_closed_s.lzsa \
book_hallway_n.lzsa book_hallway_s.lzsa \
book_hallway2_n.lzsa book_hallway2_s.lzsa \
inside_sub_e.lzsa inside_sub_w.lzsa \
bunker_entry_e.lzsa bunker_entry_w.lzsa \
sub_hallway_e.lzsa sub_hallway_w.lzsa \
@ -21,8 +22,9 @@ sub_graphics.inc: \
sub_close_n.lzsa sub_close_s.lzsa \
sub_close_open_s.lzsa \
inside_sub_back_e.lzsa inside_sub_back_closed_s.lzsa \
inside_sub_back_selena_s.lzsa \
inside_sub_selena_e.lzsa
inside_sub_back_selena_s.lzsa inside_sub_back_book_s.lzsa \
inside_sub_selena_e.lzsa inside_sub_book_e.lzsa \
outside_book_n.lzsa outside_book_s.lzsa
echo "subroom_s_lzsa: .incbin \"subroom_s.lzsa\"" > sub_graphics.inc
echo "subroom_n_lzsa: .incbin \"subroom_n.lzsa\"" >> sub_graphics.inc
echo "book_table_s_lzsa: .incbin \"book_table_s.lzsa\"" >> sub_graphics.inc
@ -39,13 +41,20 @@ sub_graphics.inc: \
echo "sub_hallway2_w_lzsa: .incbin \"sub_hallway2_w.lzsa\"" >> sub_graphics.inc
echo "book_hallway_n_lzsa: .incbin \"book_hallway_n.lzsa\"" >> sub_graphics.inc
echo "book_hallway_s_lzsa: .incbin \"book_hallway_s.lzsa\"" >> sub_graphics.inc
echo "book_hallway2_n_lzsa: .incbin \"book_hallway2_n.lzsa\"" >> sub_graphics.inc
echo "book_hallway2_s_lzsa: .incbin \"book_hallway2_s.lzsa\"" >> sub_graphics.inc
echo "sub_close_n_lzsa: .incbin \"sub_close_n.lzsa\"" >> sub_graphics.inc
echo "sub_close_s_lzsa: .incbin \"sub_close_s.lzsa\"" >> sub_graphics.inc
echo "sub_close_open_s_lzsa: .incbin \"sub_close_open_s.lzsa\"" >> sub_graphics.inc
echo "inside_sub_back_e_lzsa: .incbin \"inside_sub_back_e.lzsa\"" >> sub_graphics.inc
echo "inside_sub_back_closed_s_lzsa: .incbin \"inside_sub_back_closed_s.lzsa\"" >> sub_graphics.inc
echo "inside_sub_back_selena_s_lzsa: .incbin \"inside_sub_back_selena_s.lzsa\"" >> sub_graphics.inc
echo "inside_sub_back_book_s_lzsa: .incbin \"inside_sub_back_book_s.lzsa\"" >> sub_graphics.inc
echo "inside_sub_selena_e_lzsa: .incbin \"inside_sub_selena_e.lzsa\"" >> sub_graphics.inc
echo "inside_sub_book_e_lzsa: .incbin \"inside_sub_book_e.lzsa\"" >> sub_graphics.inc
echo "outside_book_n_lzsa: .incbin \"outside_book_n.lzsa\"" >> sub_graphics.inc
echo "outside_book_s_lzsa: .incbin \"outside_book_s.lzsa\"" >> sub_graphics.inc
%.gr: %.png
$(PNG2GR) $< $@

Binary file not shown.

After

Width:  |  Height:  |  Size: 933 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 848 B

View File

@ -177,14 +177,18 @@ location8:
.word inside_sub_selena_e_lzsa ; east bg
.word inside_sub_w_lzsa ; west bg
.byte BG_EAST|BG_WEST
.byte $ff
.byte DIRECTION_E
.byte 7,27 ; special x
.byte 24,35 ; special y
.word sub_controls_move_toward_book-1 ; special function
; SUB_INSIDE_FRONT_MOVING -- inside the submarine front, when "moving"
location9:
.byte $ff ; north exit
.byte $ff ; south exit
.byte $ff ; east exit
.byte SUB_BOOK_HALLWAY ; west exit
.byte SUB_INSIDE_BACK ; west exit
.byte $ff ; north exit_dir
.byte $ff ; south exit_dir
.byte $ff ; east exit_dir
@ -194,67 +198,55 @@ location9:
.word inside_sub_e_lzsa ; east bg
.word inside_sub_w_lzsa ; west bg
.byte BG_EAST|BG_WEST
.byte $ff
.byte DIRECTION_E
.byte 7,27 ; special x
.byte 24,40 ; special y
.word sub_controls_moving-1 ; special function
; SUB_INSIDE_FRONT_BOOK -- inside the submarine front, at book area
location10:
.byte $ff ; north exit
.byte $ff ; south exit
.byte $ff ; east exit
.byte SUB_BOOK_HALLWAY ; west exit
.byte SUB_INSIDE_BACK ; west exit
.byte $ff ; north exit_dir
.byte $ff ; south exit_dir
.byte $ff ; east exit_dir
.byte DIRECTION_S ; west exit_dir
.word $0000 ; north bg
.word $0000 ; south bg
.word inside_sub_e_lzsa ; east bg
.word inside_sub_book_e_lzsa ; east bg
.word inside_sub_w_lzsa ; west bg
.byte BG_EAST|BG_WEST
.byte $ff
.byte DIRECTION_E
.byte 7,27 ; special x
.byte 28,40 ; special y
.word sub_controls_move_toward_selena-1 ; special function
; SUB_OUTSIDE_BOOK -- outside sub in book area
location11:
.byte $ff ; north exit
.byte SUB_BOOK_ROOM ; south exit
.byte SUB_INSIDE_BACK ; north exit
.byte SUB_BOOK_HALLWAY ; south exit
.byte $ff ; east exit
.byte $ff ; west exit
.byte DIRECTION_E ; north exit_dir
.byte DIRECTION_S ; south exit_dir
.byte $ff ; east exit_dir
.byte $ff ; west exit_dir
.word book_hallway_n_lzsa ; north bg
.word book_hallway_s_lzsa ; south bg
.word outside_book_n_lzsa ; north bg
.word outside_book_s_lzsa ; south bg
.word $0000 ; east bg
.word $0000 ; west bg
.byte BG_NORTH|BG_SOUTH
.byte $ff
; SUB_OUTSIDE_BOOK_OPEN -- outside sub in book area, door open
location12:
.byte $ff ; north exit
.byte SUB_BOOK_ROOM ; south exit
.byte $ff ; east exit
.byte $ff ; west exit
.byte DIRECTION_E ; north exit_dir
.byte DIRECTION_S ; south exit_dir
.byte $ff ; east exit_dir
.byte $ff ; west exit_dir
.word book_hallway_n_lzsa ; north bg
.word book_hallway_s_lzsa ; south bg
.word $0000 ; east bg
.word $0000 ; west bg
.byte BG_NORTH|BG_SOUTH
.byte $ff
; SUB_BOOK_HALLWAY -- hallway to the book room
location13:
.byte $ff ; north exit
.byte SUB_BOOK_ROOM ; south exit
location12:
.byte SUB_OUTSIDE_BOOK ; north exit
.byte SUB_BOOK_HALLWAY2 ; south exit
.byte $ff ; east exit
.byte $ff ; west exit
.byte DIRECTION_E ; north exit_dir
.byte DIRECTION_N ; north exit_dir
.byte DIRECTION_S ; south exit_dir
.byte $ff ; east exit_dir
.byte $ff ; west exit_dir
@ -265,9 +257,26 @@ location13:
.byte BG_NORTH|BG_SOUTH
.byte $ff
; SUB_BOOK_HALLWAY2 -- hallway to the book room
location13:
.byte SUB_BOOK_HALLWAY ; north exit
.byte SUB_BOOK_ROOM ; south exit
.byte $ff ; east exit
.byte $ff ; west exit
.byte DIRECTION_N ; north exit_dir
.byte DIRECTION_S ; south exit_dir
.byte $ff ; east exit_dir
.byte $ff ; west exit_dir
.word book_hallway2_n_lzsa ; north bg
.word book_hallway2_s_lzsa ; south bg
.word $0000 ; east bg
.word $0000 ; west bg
.byte BG_NORTH|BG_SOUTH
.byte $ff
; SELENA_BOOK_ROOM -- book room
location14:
.byte SUB_BOOK_HALLWAY ; north exit
.byte SUB_BOOK_HALLWAY2 ; north exit
.byte SUB_BOOK_CLOSED ; south exit
.byte $ff ; east exit
.byte $ff ; west exit

View File

@ -220,6 +220,144 @@ sub_door_close:
jmp change_location
;=====================
; sub controls
;=====================
;====================
; toward_book
sub_controls_move_toward_book:
; disable exit button
ldy #LOCATION_SPECIAL_EXIT
lda #$ff
sta location6,Y ; SUB_INSIDE_BACK
; change so we use split mode when looking E
ldy #LOCATION_EAST_EXIT_DIR
lda #DIRECTION_E|DIRECTION_SPLIT
sta location6,Y ; SUB INSIDE_BACK
; any controls take us to moving
sta DIRECTION
lda #SUB_INSIDE_FRONT_MOVING
sta LOCATION
jmp change_location
;====================
; toward_selena
sub_controls_move_toward_selena:
; disable exit button
ldy #LOCATION_SPECIAL_EXIT
lda #$ff
sta location6,Y ; SUB_INSIDE_BACK
; change so we use split mode when looking E
ldy #LOCATION_EAST_EXIT_DIR
lda #DIRECTION_E|DIRECTION_SPLIT
sta location6,Y ; SUB INSIDE_BACK
; any controls take us to moving
sta DIRECTION
; change destination of front of sub
ldy #LOCATION_EAST_EXIT
lda #SUB_INSIDE_FRONT_MOVING
sta location7,Y ; SUB_INSIDE_BACK_OPEN
sta location6,Y ; SUN_INSIDE_BACK
lda #SUB_INSIDE_FRONT_MOVING
sta LOCATION
jmp change_location
;===============================
; moving
sub_controls_moving:
; re-enable exit button
ldy #LOCATION_SPECIAL_EXIT
lda #DIRECTION_S
sta location6,Y ; SUB_INSIDE_BACK
; change so we use normal (not split) mode when looking forward
ldy #LOCATION_EAST_EXIT_DIR
lda #DIRECTION_E
sta location6,Y ; SUB INSIDE_BACK
sta DIRECTION
lda CURSOR_Y
cmp #32
bcc sub_forward ; blt
; "backward" taks us back to selena
sub_backward:
; change destination of open door
ldy #LOCATION_SOUTH_EXIT
lda #SUB_CLOSE_OPEN
sta location7,Y ; SUB_INSIDE_BACK_OPEN
ldy #LOCATION_SOUTH_EXIT_DIR
lda #DIRECTION_N
sta location7,Y ; SUB_INSIDE_BACK_OPEN
; change destination of front of sub
ldy #LOCATION_EAST_EXIT
lda #SUB_INSIDE_FRONT_SELENA
sta location7,Y ; SUB_INSIDE_BACK_OPEN
sta location6,Y ; SUN_INSIDE_BACK
; change background of open door
ldy #LOCATION_SOUTH_BG
lda #<inside_sub_back_selena_s_lzsa
sta location7,Y
lda #>inside_sub_back_selena_s_lzsa
sta location7+1,Y ; SUB_INSIDE_BACK_OPEN
lda #SUB_INSIDE_FRONT_SELENA
sta LOCATION
jmp change_location
; "forward" takes us to book
sub_forward:
; change destination of open door
ldy #LOCATION_SOUTH_EXIT
lda #SUB_OUTSIDE_BOOK
sta location7,Y ; SUB_INSIDE_BACK_OPEN
ldy #LOCATION_SOUTH_EXIT_DIR
lda #DIRECTION_S
sta location7,Y ; SUB_INSIDE_BACK_OPEN
; change destination of front of sub
ldy #LOCATION_EAST_EXIT
lda #SUB_INSIDE_FRONT_BOOK
sta location7,Y ; SUB_INSIDE_BACK_OPEN
sta location6,Y ; SUN_INSIDE_BACK
; change background of open door
ldy #LOCATION_SOUTH_BG
lda #<inside_sub_back_book_s_lzsa
sta location7,Y
lda #>inside_sub_back_book_s_lzsa
sta location7+1,Y ; SUB_INSIDE_BACK_OPEN
lda #SUB_INSIDE_FRONT_BOOK
sta LOCATION
jmp change_location
; 1 2 3
;123456789012345678901234567890123456789
; FOR THE SAKE OF ARGUMENT IMAGINE YOU
; JUST SPENT 45 MINUTES NAVIGATING AN
; OBSCURE MAZE BASED ON A CLUE YOU WERE
; SUPPOSED TO NOTICE IN MECHANICAL AGE
;==========================
; includes
;==========================
@ -232,8 +370,6 @@ sub_door_close:
; linking books
.include "link_book_mist.s"
; .include "handle_pages.s"
; level data
.include "leveldata_sub.inc"
@ -243,3 +379,7 @@ sub_door_close:
; sub solution
; N, W, N, E, E
; S, S, W, SW, W
; NW, NE, N, SE