diff --git a/games/riven_hgr/Makefile b/games/riven_hgr/Makefile index a0068ab7..c8d7ae42 100644 --- a/games/riven_hgr/Makefile +++ b/games/riven_hgr/Makefile @@ -151,7 +151,8 @@ riven_disk05.dsk: QBOOT QLOAD TITLE_05 \ ### riven_disk10.dsk: QBOOT QLOAD TITLE_10 \ - disk10_files/LEVEL_INSIDE + disk10_files/LEVEL_INSIDE \ + disk10_files/LEVEL_STAINED cp $(EMPTY_DISK)/empty.dsk riven_disk10.dsk $(DOS33_RAW) riven_disk10.dsk 0 0 QBOOT 0 1 $(DOS33_RAW) riven_disk10.dsk 0 2 QBOOT 1 1 @@ -160,6 +161,8 @@ riven_disk10.dsk: QBOOT QLOAD TITLE_10 \ $(DOS33_RAW) riven_disk10.dsk 0 8 TITLE_10 0 0 $(DOS33_RAW) riven_disk10.dsk 1 0 QLOAD 0 0 $(DOS33_RAW) riven_disk10.dsk 2 0 disk10_files/LEVEL_INSIDE 0 0 + $(DOS33_RAW) riven_disk10.dsk 8 0 disk10_files/LEVEL_STAINED 0 0 + ### @@ -618,6 +621,9 @@ disk05_files/LEVEL_CHAIR: disk10_files/LEVEL_INSIDE: cd disk10_files && make +disk10_files/LEVEL_STAINED: + cd disk10_files && make + #### disk38_files/LEVEL_PROJECTOR: @@ -832,6 +838,7 @@ riven_hgr.2mg: dts_block PROBOOTHD QLOAD_HD \ disk05_files/LEVEL_CHAIR \ disk10_files/DISK10 \ disk10_files/LEVEL_INSIDE \ + disk10_files/LEVEL_STAINED \ disk38_files/DISK38 \ disk38_files/LEVEL_PROJECTOR \ disk39_files/DISK39 \ @@ -906,6 +913,7 @@ riven_hgr.2mg: dts_block PROBOOTHD QLOAD_HD \ $(PRODOS_RAW) riven_hgr.2mg `./dts_block 5 2 0` disk05_files/LEVEL_CHAIR 0 0 $(PRODOS_RAW) riven_hgr.2mg `./dts_block 10 0 2` disk10_files/DISK10 0 0 $(PRODOS_RAW) riven_hgr.2mg `./dts_block 10 2 0` disk10_files/LEVEL_INSIDE 0 0 + $(PRODOS_RAW) riven_hgr.2mg `./dts_block 10 8 0` disk10_files/LEVEL_STAINED 0 0 $(PRODOS_RAW) riven_hgr.2mg `./dts_block 38 0 2` disk38_files/DISK38 0 0 $(PRODOS_RAW) riven_hgr.2mg `./dts_block 38 2 0` disk38_files/LEVEL_PROJECTOR 0 0 $(PRODOS_RAW) riven_hgr.2mg `./dts_block 39 0 2` disk39_files/DISK39 0 0 diff --git a/games/riven_hgr/NOTES b/games/riven_hgr/NOTES index 3aec5b93..8068ec0e 100644 --- a/games/riven_hgr/NOTES +++ b/games/riven_hgr/NOTES @@ -122,6 +122,16 @@ T 0.5 = TITLE 1805 bytes 8S = 0T8S (2048) 400B free T 1 = QLOAD 2314 bytes 16S= 1T0S (4096) 2k free T 2 = CHAIR 1195 bytes = 6T0S (24576) 23k free +Disk10 Map (disk has 35 tracks, each 4k in size) +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +T 0 = Qboot +T 0.5 = TITLE 1805 bytes 8S = 0T8S (2048) 400B free +T 1 = QLOAD 2314 bytes 16S= 1T0S (4096) 2k free +T 2 = INSIDE 17137 bytes = 6T0S (24576) 7k free +T 8 = STAINED 15420 bytes = 6T0S (24576) 9k free + + + Disk38 Map (disk has 35 tracks, each 4k in size) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ T 0 = Qboot @@ -280,3 +290,36 @@ IN_LEFT if X>20 and forward -> dest1 if X<20 and forward -> dest2 + + +rotating room -- rotates clockwise. B initially blocked + / \ + B / \ -- rotation 0, can get to B and E. C is blocked + /O \Q -- rotation 1, both E and C blocked + / \ -- rotation 2, E blocked. B + C open + \ /C -- rotation 3, E and Q open + P\__O__/ -- rotation 4, C and P open (pipe) + E can flip telescope controls + can flip wall handle. also another button + flip twice to get to Q, also handle and + button (both needed to get to dome) + rotate button at B as well + + + +settings for rotating toom + 80 (shadow) / 81 (bright) / 66 (contrast) + +stained glass: + crop to actual size + run "erode" + scale to 192 high + canvas size 280x192 + grid 2x2 + reduce to 16 colors + paint paint paint + draw border + + + + diff --git a/games/riven_hgr/disk10_files/Makefile b/games/riven_hgr/disk10_files/Makefile index fdf64b70..4ff4fc5b 100644 --- a/games/riven_hgr/disk10_files/Makefile +++ b/games/riven_hgr/disk10_files/Makefile @@ -3,7 +3,7 @@ include ../../../Makefile.inc LINKER_SCRIPTS = ../../../linker_scripts/ -all: DISK10 LEVEL_INSIDE +all: DISK10 LEVEL_INSIDE LEVEL_STAINED #### @@ -22,12 +22,24 @@ level_inside.o: level_inside.s \ ../zp.inc ../hardware.inc ../qload.inc \ ../common_defines.inc disk10_defines.inc \ leveldata_inside.inc \ - graphics_inside/inside_graphics.inc \ - graphics_stained/stained_graphics.inc + graphics_inside/inside_graphics.inc ca65 -o level_inside.o level_inside.s -l level_inside.lst #### +LEVEL_STAINED: level_stained.o + ld65 -o LEVEL_STAINED level_stained.o -C $(LINKER_SCRIPTS)/apple2_4000.inc + +level_stained.o: level_stained.s \ + ../zp.inc ../hardware.inc ../qload.inc \ + ../common_defines.inc disk10_defines.inc \ + leveldata_stained.inc \ + graphics_stained/stained_graphics.inc + ca65 -o level_stained.o level_stained.s -l level_stained.lst + + +#### + graphics_inside/inside_graphics.inc: cd graphics_inside && make @@ -38,12 +50,14 @@ graphics_stained/stained_graphics.inc: clean: rm -f *~ *.o *.lst DISK10 \ - LEVEL_INSIDE + LEVEL_INSIDE LEVEL_STAINED #### distclean: rm -f *~ *.o *.lst DISK10 \ - LEVEL_INSIDE + LEVEL_INSIDE LEVEL_STAINED cd graphics_inside && make clean + cd graphics_stained && make clean + diff --git a/games/riven_hgr/disk10_files/disk10.s b/games/riven_hgr/disk10_files/disk10.s index adde8c9c..ea661f6e 100644 --- a/games/riven_hgr/disk10_files/disk10.s +++ b/games/riven_hgr/disk10_files/disk10.s @@ -9,19 +9,19 @@ which_disk_bin: .byte 10 load_address_array: - .byte $40,$40,$40,$40 ; TITLE, INSIDE + .byte $40,$40,$40,$40 ; TITLE, INSIDE, STAINED .byte $40,$40,$40,$40 ; track_array: - .byte 0, 2, 7,12 ; TITLE, INSIDE + .byte 0, 2, 8,12 ; TITLE, INSIDE, STAINED .byte 17,22,27,0 ; sector_array: - .byte 8, 0, 0, 0 ; TITLE, INSIDE + .byte 8, 0, 0, 0 ; TITLE, INSIDE, STAINED .byte 0,0,0,0 ; length_array: - .byte 8, 80,80,80 ; TITLE, INSIDE + .byte 8, 96,96,80 ; TITLE, INSIDE, STAINED .byte 80,80,80,0 ; diff --git a/games/riven_hgr/disk10_files/disk10_defines.inc b/games/riven_hgr/disk10_files/disk10_defines.inc index e5a45abf..37736945 100644 --- a/games/riven_hgr/disk10_files/disk10_defines.inc +++ b/games/riven_hgr/disk10_files/disk10_defines.inc @@ -1,9 +1,20 @@ LOAD_TITLE_10 = 0 LOAD_INSIDE = 1 +LOAD_STAINED = 2 ;================================ ; Level definitions ; INSIDE RIVEN_INSIDE = 0 -RIVEN_STAINED3 = 1 +RIVEN_PILLAR_23 = 1 +RIVEN_PILLAR_51 = 2 +RIVEN_PILLAR_12 = 3 +RIVEN_PILLAR_34 = 4 +RIVEN_PILLAR_45 = 5 + +; STAINED +RIVEN_BEETLE_FAR_R = 0 +RIVEN_BEETLE_CLOSE = 1 +RIVEN_STAINED2 = 2 +RIVEN_STAINED3 = 3 diff --git a/games/riven_hgr/disk10_files/graphics_inside/Makefile b/games/riven_hgr/disk10_files/graphics_inside/Makefile index e705ab45..ef0301c0 100644 --- a/games/riven_hgr/disk10_files/graphics_inside/Makefile +++ b/games/riven_hgr/disk10_files/graphics_inside/Makefile @@ -6,9 +6,13 @@ PNG_TO_HGR = ../../../../utils/hgr-utils/png2hgr all: inside_graphics.inc inside_graphics.inc: \ - entrance_w.hgr.zx02 entrance_e.hgr.zx02 + entrance_w.hgr.zx02 entrance_e.hgr.zx02 \ + pillars_23.hgr.zx02 pillars_51.hgr.zx02 echo "entrance_w_zx02: .incbin \"entrance_w.hgr.zx02\"" > inside_graphics.inc echo "entrance_e_zx02: .incbin \"entrance_e.hgr.zx02\"" >> inside_graphics.inc + echo "pillars_23_zx02: .incbin \"pillars_23.hgr.zx02\"" >> inside_graphics.inc + echo "pillars_51_zx02: .incbin \"pillars_51.hgr.zx02\"" >> inside_graphics.inc + #### diff --git a/games/riven_hgr/disk10_files/graphics_inside/pillars_23.png b/games/riven_hgr/disk10_files/graphics_inside/pillars_23.png new file mode 100644 index 00000000..2dd39a0f Binary files /dev/null and b/games/riven_hgr/disk10_files/graphics_inside/pillars_23.png differ diff --git a/games/riven_hgr/disk10_files/graphics_inside/pillars_51.png b/games/riven_hgr/disk10_files/graphics_inside/pillars_51.png new file mode 100644 index 00000000..89a9a269 Binary files /dev/null and b/games/riven_hgr/disk10_files/graphics_inside/pillars_51.png differ diff --git a/games/riven_hgr/disk10_files/graphics_stained/Makefile b/games/riven_hgr/disk10_files/graphics_stained/Makefile index 9787dea2..ffbbb80a 100644 --- a/games/riven_hgr/disk10_files/graphics_stained/Makefile +++ b/games/riven_hgr/disk10_files/graphics_stained/Makefile @@ -6,8 +6,13 @@ PNG_TO_HGR = ../../../../utils/hgr-utils/png2hgr all: stained_graphics.inc stained_graphics.inc: \ - stained03.hgr.zx02 - echo "stained03_zx02: .incbin \"stained03.hgr.zx02\"" > stained_graphics.inc + stained02.hgr.zx02 stained03.hgr.zx02 \ + beetle_far_r.hgr.zx02 beetle_close.hgr.zx02 + echo "stained02_zx02: .incbin \"stained02.hgr.zx02\"" > stained_graphics.inc + echo "stained03_zx02: .incbin \"stained03.hgr.zx02\"" >> stained_graphics.inc + echo "beetle_far_r_zx02: .incbin \"beetle_far_r.hgr.zx02\"" >> stained_graphics.inc + echo "beetle_close_zx02: .incbin \"beetle_close.hgr.zx02\"" >> stained_graphics.inc + #### diff --git a/games/riven_hgr/disk10_files/graphics_stained/beetle_close.png b/games/riven_hgr/disk10_files/graphics_stained/beetle_close.png new file mode 100644 index 00000000..8b6f5951 Binary files /dev/null and b/games/riven_hgr/disk10_files/graphics_stained/beetle_close.png differ diff --git a/games/riven_hgr/disk10_files/graphics_stained/beetle_close_old.png b/games/riven_hgr/disk10_files/graphics_stained/beetle_close_old.png new file mode 100644 index 00000000..5f2f450a Binary files /dev/null and b/games/riven_hgr/disk10_files/graphics_stained/beetle_close_old.png differ diff --git a/games/riven_hgr/disk10_files/graphics_stained/beetle_far_r.png b/games/riven_hgr/disk10_files/graphics_stained/beetle_far_r.png new file mode 100644 index 00000000..c94441c5 Binary files /dev/null and b/games/riven_hgr/disk10_files/graphics_stained/beetle_far_r.png differ diff --git a/games/riven_hgr/disk10_files/graphics_stained/stained02.png b/games/riven_hgr/disk10_files/graphics_stained/stained02.png new file mode 100644 index 00000000..cb2c96db Binary files /dev/null and b/games/riven_hgr/disk10_files/graphics_stained/stained02.png differ diff --git a/games/riven_hgr/disk10_files/level_inside.s b/games/riven_hgr/disk10_files/level_inside.s index 7f6bb31a..911b76c6 100644 --- a/games/riven_hgr/disk10_files/level_inside.s +++ b/games/riven_hgr/disk10_files/level_inside.s @@ -102,6 +102,49 @@ really_exit: rts + ;========================== + ; handle pillars 2/3 + ;========================== +handle_pillars_23: + + ; if 13 or to pillar 2 + ; if 26 or more, go to pillar 3 + ; otherwise, go to center path (nothing for now) + + lda CURSOR_X + cmp #26 + bcs go_pillar3 + + cmp #13 + bcc go_pillar2 + + rts + +go_pillar3: + lda #LOAD_STAINED + sta WHICH_LOAD + + lda #RIVEN_BEETLE_FAR_R + sta LOCATION + + lda #DIRECTION_W + bne done_dir ; bra + +go_pillar2: + lda #LOAD_STAINED + sta WHICH_LOAD + + lda #RIVEN_BEETLE_FAR_R + sta LOCATION + + lda #DIRECTION_W +done_dir: + sta DIRECTION + + lda #1 + sta LEVEL_OVER + rts + ;========================== ; includes @@ -109,6 +152,5 @@ really_exit: .include "graphics_inside/inside_graphics.inc" -.include "graphics_stained/stained_graphics.inc" .include "leveldata_inside.inc" diff --git a/games/riven_hgr/disk10_files/level_stained.s b/games/riven_hgr/disk10_files/level_stained.s new file mode 100644 index 00000000..27c6d07c --- /dev/null +++ b/games/riven_hgr/disk10_files/level_stained.s @@ -0,0 +1,114 @@ +; Riven -- Looking at Beetles + +; by deater (Vince Weaver) + +; Zero Page + .include "../zp.inc" + .include "../hardware.inc" + .include "../common_defines.inc" + .include "../qload.inc" + .include "disk10_defines.inc" + +stained_start: + + ;=================== + ; init screen + ;=================== + +; jsr TEXT +; jsr HOME + bit KEYRESET + + bit SET_GR + bit PAGE1 + bit HIRES + bit FULLGR + + ;======================== + ; set up location + ;======================== + + lda #locations + sta LOCATIONS_H + + lda #0 + sta DRAW_PAGE + sta LEVEL_OVER + + lda #0 + sta JOYSTICK_ENABLED + sta UPDATE_POINTER + + lda #1 + sta CURSOR_VISIBLE + + lda #20 + sta CURSOR_X + sta CURSOR_Y + + + + + ;=================================== + ; init + ;=================================== + +; done in title + +; lda #$20 +; sta HGR_PAGE +; jsr hgr_make_tables + + jsr change_location + + jsr save_bg_14x14 ; save old bg + +game_loop: + + ;=================================== + ; draw pointer + ;=================================== + + jsr draw_pointer + + ;=================================== + ; handle keypress/joystick + ;=================================== + + jsr handle_keypress + + ;=================================== + ; increment frame count + ;=================================== + + inc FRAMEL + bne frame_no_oflo + + inc FRAMEH +frame_no_oflo: + + ;==================================== + ; check level over + ;==================================== + + lda LEVEL_OVER + bne really_exit + + jmp game_loop + +really_exit: + + rts + + + ;========================== + ; includes + ;========================== + + + +.include "graphics_stained/stained_graphics.inc" + +.include "leveldata_stained.inc" diff --git a/games/riven_hgr/disk10_files/leveldata_inside.inc b/games/riven_hgr/disk10_files/leveldata_inside.inc index 0afcfb2b..d50b85e6 100644 --- a/games/riven_hgr/disk10_files/leveldata_inside.inc +++ b/games/riven_hgr/disk10_files/leveldata_inside.inc @@ -3,7 +3,7 @@ ;=============================================== locations: - .word location0,location1 + .word location0,location1,location2 ; RIVEN_INSIDE -- part way across the bridge @@ -11,7 +11,7 @@ location0: .byte $ff ; north exit .byte $ff ; south exit .byte $E0 ; east exit - .byte RIVEN_STAINED3 ; west exit + .byte RIVEN_PILLAR_23 ; west exit .byte $FF ; north exit_dir .byte $FF ; south exit_dir .byte DIRECTION_E ; east exit_dir @@ -23,9 +23,32 @@ location0: .byte BG_EAST|BG_WEST .byte $ff ; special exit -; RIVEN_STAINED3 -- stained glass image +; RIVEN_PILLAR23 location1: + .byte $ff ; north exit + .byte $ff ; south exit + .byte RIVEN_INSIDE ; east exit + .byte $FF ; west exit + .byte $FF ; north exit_dir + .byte $FF ; south exit_dir + .byte DIRECTION_E ; east exit_dir + .byte DIRECTION_W ; west exit_dir + .word $0000 ; north bg + .word $0000 ; south bg + .word pillars_51_zx02 ; east bg + .word pillars_23_zx02 ; west bg + .byte BG_WEST|BG_EAST + .byte DIRECTION_W|DIRECTION_ONLY_POINT ; special exit + .byte 7,33 + .byte 0,180 + .word handle_pillars_23-1 + + + +; RIVEN_PILLAR51 + +location2: .byte $ff ; north exit .byte $ff ; south exit .byte $ff ; east exit @@ -37,8 +60,9 @@ location1: .word $0000 ; north bg .word $0000 ; south bg .word $0000 ; east bg - .word stained03_zx02 ; west bg + .word pillars_51_zx02 ; west bg .byte BG_WEST .byte $ff ; special exit + diff --git a/games/riven_hgr/disk10_files/leveldata_stained.inc b/games/riven_hgr/disk10_files/leveldata_stained.inc new file mode 100644 index 00000000..ad1d4ef0 --- /dev/null +++ b/games/riven_hgr/disk10_files/leveldata_stained.inc @@ -0,0 +1,83 @@ +;=============================================== +; level data for looking at stained glass +;=============================================== + +locations: + .word location0,location1,location2,location3 + +; RIVEN_BEETLE_FAR_R + +location0: + .byte $ff ; north exit + .byte $ff ; south exit + .byte $FF ; east exit + .byte RIVEN_BEETLE_CLOSE ; west exit + .byte $FF ; north exit_dir + .byte $FF ; south exit_dir + .byte $FF ; east exit_dir + .byte DIRECTION_W ; west exit_dir + .word $0000 ; north bg + .word $0000 ; south bg + .word $0000 ; east bg + .word beetle_far_r_zx02 ; west bg + .byte BG_WEST + .byte $ff ; special exit + +; RIVEN_BEETLE_CLOSE + +location1: + .byte $ff ; north exit + .byte $ff ; south exit + .byte $FF ; east exit + .byte RIVEN_STAINED2 ; west exit + .byte $FF ; north exit_dir + .byte $FF ; south exit_dir + .byte $FF ; east exit_dir + .byte DIRECTION_W ; west exit_dir + .word $0000 ; north bg + .word $0000 ; south bg + .word $0000 ; east bg + .word beetle_close_zx02 ; west bg + .byte BG_WEST + .byte $ff ; special exit + +; RIVEN_STAINED02 + +location2: + .byte $ff ; north exit + .byte $ff ; south exit + .byte $FF ; east exit + .byte $FF ; west exit + .byte $FF ; north exit_dir + .byte $FF ; south exit_dir + .byte $FF ; east exit_dir + .byte $ff ; west exit_dir + .word $0000 ; north bg + .word $0000 ; south bg + .word $0000 ; east bg + .word stained02_zx02 ; west bg + .byte BG_WEST + .byte $ff ; special exit + +; RIVEN_STAINED03 + +location3: + .byte $ff ; north exit + .byte $ff ; south exit + .byte $FF ; east exit + .byte $FF ; west exit + .byte $FF ; north exit_dir + .byte $FF ; south exit_dir + .byte $FF ; east exit_dir + .byte $ff ; west exit_dir + .word $0000 ; north bg + .word $0000 ; south bg + .word $0000 ; east bg + .word stained03_zx02 ; west bg + .byte BG_WEST + .byte $ff ; special exit + + + + +