From 66bf6753f6e11c6b37201a928ded7ec23ecef6f6 Mon Sep 17 00:00:00 2001 From: Vince Weaver Date: Thu, 17 Feb 2022 23:57:24 -0500 Subject: [PATCH] peasant: animate guy in boat --- games/peasant/NOTES | 17 ++++++----- games/peasant/animate_bubbles.s | 4 +-- games/peasant/graphics_peasantry/Makefile | 4 +-- games/peasant/peasant3.s | 36 ++++++++++++++++++++++- games/peasant/sprites/Makefile | 22 ++++++++------ 5 files changed, 60 insertions(+), 23 deletions(-) diff --git a/games/peasant/NOTES b/games/peasant/NOTES index f457f84d..5a91af54 100644 --- a/games/peasant/NOTES +++ b/games/peasant/NOTES @@ -15,6 +15,7 @@ Common parser: 4c2 - 156e = 10ac 4268 bytes +peasant3 18554 -> 22442 peasant2 18302 18043 (decompress fast moved) @@ -76,19 +77,19 @@ $08-$0B Text/GR page 2. $08=boot, $09-$0A = qboot stage2 $0B-$1F QLOAD disk routines and HGR drawing routines (5120 bytes) $20-$3F HGR Page 1 $40-$5f HGR Page 2 -$60-$AF Programs (roughly 22k available?) (we max at 20k on disk) +$60-$AF Programs (we limit to 20k, 20480 bytes, $50 pages) +$B0-$?? $B8-$BB Hi-res lookup tables $BC temp area for load/save files $BD-$BE temp area when saving game $BF verb table $C0-$CF I/O -$D0-$DF (Language Card BANK1) ????? -$D0-$DF (Language Card BANK2) Mockingboard music/PT3-routines -$E0-$FF (Language Card) ????? -$D0-$DF (bank2) inventory -$D0-$ED (bank1) per-levelstrings -$EE-$FF common parser code (4.5k = 4608 bytes) +Language card (high 16k) + +$D0-$ED (bank1) per-levelstrings +$D0-$DF (bank2) inventory (3122 bytes) +$EE-$FF common parser code (4.5k = 4608 bytes [4332 currently]) Disk1 Map (disk has 35 tracks, each 4k in size) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -99,7 +100,7 @@ T 4 = VID_LOGO 7574 bytes 30S = 1T14S T 6 = TITLE 8950 bytes 35S = 2T3S T 9 = INTRO 13467 bytes 52S = 3T4S T 14 = INVENTORY 3121 bytes 13S = 0T13S -T 15 = PEASANT1 17007 bytes 67S = 4T3S ; 88 is max? +T 15 = PEASANT1 17007 bytes 67S = 4T3S ; 80 is max T 20 = PEASANT2 17941 bytes 71S = 4T7S ; 79 = 20224 T 25 = PEASANT3 18154 bytes 71S = 4T7S T 30 = PEASANT4 15806 bytes 62S = 3T14S diff --git a/games/peasant/animate_bubbles.s b/games/peasant/animate_bubbles.s index 7b0c37e1..79062f8e 100644 --- a/games/peasant/animate_bubbles.s +++ b/games/peasant/animate_bubbles.s @@ -68,9 +68,7 @@ animate_bubbles_e: lda #130 sta CURSOR_Y - jsr hgr_draw_sprite ;_1x5 - - rts + jmp hgr_draw_sprite ;_1x5 bubble_progress_e: diff --git a/games/peasant/graphics_peasantry/Makefile b/games/peasant/graphics_peasantry/Makefile index 5fe6e8f3..0a3e12cf 100644 --- a/games/peasant/graphics_peasantry/Makefile +++ b/games/peasant/graphics_peasantry/Makefile @@ -71,8 +71,8 @@ graphics_peasant3.inc: \ echo "jhonka_lzsa: .incbin \"jhonka.lzsa\"" > graphics_peasant3.inc echo "cottage_lzsa: .incbin \"cottage.lzsa\"" >> graphics_peasant3.inc echo "lake_w_lzsa: .incbin \"lake_w.lzsa\"" >> graphics_peasant3.inc -# echo "lake_e_lzsa: .incbin \"lake_e.lzsa\"" >> graphics_peasant3.inc - echo "lake_e_lzsa: .incbin \"lake_e_boat.lzsa\"" >> graphics_peasant3.inc + echo "lake_e_lzsa: .incbin \"lake_e.lzsa\"" >> graphics_peasant3.inc +# echo "lake_e_lzsa: .incbin \"lake_e_boat.lzsa\"" >> graphics_peasant3.inc # echo "lake_e_boat_lzsa: .incbin \"lake_e_boat.lzsa\"" >> graphics_peasant3.inc echo "inn_lzsa: .incbin \"inn.lzsa\"" >> graphics_peasant3.inc diff --git a/games/peasant/peasant3.s b/games/peasant/peasant3.s index da852176..e0e98622 100644 --- a/games/peasant/peasant3.s +++ b/games/peasant/peasant3.s @@ -257,6 +257,40 @@ game_loop: at_lake_east: jsr animate_bubbles_e + + ; draw dude + + lda GAME_STATE_1 + and #FISH_FED + bne done_dude + + lda FRAME + and #$8 + beq draw_boat1 + +draw_boat0: + lda #boat0 + jmp done_choose_boat +draw_boat1: + lda #boat1 + +done_choose_boat: + sta INH + + lda #1 + sta CURSOR_X + lda #70 + sta CURSOR_Y + + jsr hgr_draw_sprite + +done_dude: + + jmp skip_level_specific at_lake_west: @@ -303,7 +337,7 @@ level_over: .include "graphics_peasantry/graphics_peasant3.inc" -;.include "sprites/boat_sprites.inc" +.include "sprites/boat_sprites.inc" map_backgrounds_low: .byte boat_sprites.inc - $(HGR_SPRITE) -s -l boat1 boat_sprites.png 7 47 81 91 >> boat_sprites.inc - $(HGR_SPRITE) -s -l boat2 boat_sprites.png 7 93 81 137 >> boat_sprites.inc - $(HGR_SPRITE) -s -l boat3 boat_sprites.png 7 139 81 183 >> boat_sprites.inc - $(HGR_SPRITE) -s -l boat4 boat_sprites.png 91 1 165 45 >> boat_sprites.inc - $(HGR_SPRITE) -s -l boat5 boat_sprites.png 91 47 165 91 >> boat_sprites.inc - $(HGR_SPRITE) -s -l boat6 boat_sprites.png 91 93 165 137 >> boat_sprites.inc - $(HGR_SPRITE) -s -l boat7 boat_sprites.png 91 139 165 183 >> boat_sprites.inc +# $(HGR_SPRITE) -s -l boat0 boat_sprites.png 7 1 81 45 > boat_sprites.inc +# $(HGR_SPRITE) -s -l boat1 boat_sprites.png 7 47 81 91 >> boat_sprites.inc + $(HGR_SPRITE) -s -l boat0 boat_sprites.png 7 19 62 45 > boat_sprites.inc + $(HGR_SPRITE) -s -l boat1 boat_sprites.png 7 65 62 90 >> boat_sprites.inc + +boat_sprites_fish.inc: boat_sprites.png + $(HGR_SPRITE) -s -l boat2 boat_sprites.png 7 93 81 137 > boat_sprites_fish.inc + $(HGR_SPRITE) -s -l boat3 boat_sprites.png 7 139 81 183 >> boat_sprites_fish.inc + $(HGR_SPRITE) -s -l boat4 boat_sprites.png 91 1 165 45 >> boat_sprites_fish.inc + $(HGR_SPRITE) -s -l boat5 boat_sprites.png 91 47 165 91 >> boat_sprites_fish.inc + $(HGR_SPRITE) -s -l boat6 boat_sprites.png 91 93 165 137 >> boat_sprites_fish.inc + $(HGR_SPRITE) -s -l boat7 boat_sprites.png 91 139 165 183 >> boat_sprites_fish.inc ned_sprites.inc: ned_sprites.png $(HGR_SPRITE) -s -l rock_moved_sprite ned_sprites.png 7 1 27 12 > ned_sprites.inc