dos33fsprogs/games/monkey/monkey_bar_inside2.s

282 lines
4.4 KiB
ArmAsm
Raw Normal View History

2020-09-25 03:33:59 +00:00
; stuff regarding 2nd room of scumm bar
2020-10-01 19:07:02 +00:00
; if x<4 goto MONKEY_BAR_INSIDE1 at 34,24
2020-09-25 03:33:59 +00:00
bar_inside2_check_exit:
lda GUYBRUSH_X
cmp #4
2020-09-29 19:14:21 +00:00
bcc bar_inside2_to_bar_inside1
2020-10-11 14:35:06 +00:00
cmp #33
bcs bar_inside2_to_bar_inside3
2020-10-20 00:54:47 +00:00
bcc bar_inside2_no_exit
2020-09-25 03:33:59 +00:00
2020-09-29 19:14:21 +00:00
bar_inside2_to_bar_inside1:
lda GUYBRUSH_DIRECTION
cmp #DIR_LEFT
bne bar_inside2_no_exit
lda #MONKEY_BAR_INSIDE1
2020-09-25 03:33:59 +00:00
sta LOCATION
2020-09-29 19:14:21 +00:00
lda #34
2020-09-25 03:33:59 +00:00
sta GUYBRUSH_X
sta DESTINATION_X
2020-10-01 19:07:02 +00:00
lda #24
2020-09-25 03:33:59 +00:00
sta GUYBRUSH_Y
sta DESTINATION_Y
jsr change_location
jmp bar_inside2_no_exit
2020-10-11 14:35:06 +00:00
bar_inside2_to_bar_inside3:
lda GUYBRUSH_DIRECTION
cmp #DIR_RIGHT
bne bar_inside2_no_exit
lda #MONKEY_BAR_INSIDE3
sta LOCATION
lda #5
sta GUYBRUSH_X
sta DESTINATION_X
lda #24
sta GUYBRUSH_Y
sta DESTINATION_Y
jsr change_location
jmp bar_inside2_no_exit
2020-09-25 03:33:59 +00:00
bar_inside2_no_exit:
rts
2020-09-29 19:14:21 +00:00
;================================
;================================
2020-09-25 03:33:59 +00:00
; bar_inside2 adjust destination
2020-09-29 19:14:21 +00:00
;================================
;================================
2020-09-25 03:33:59 +00:00
bar_inside2_adjust_destination:
2020-09-29 19:14:21 +00:00
; just make Y always 24
2020-09-25 03:33:59 +00:00
2020-09-29 19:14:21 +00:00
lda #24
2020-09-25 03:33:59 +00:00
sta DESTINATION_Y
2020-10-11 14:35:06 +00:00
; lda DESTINATION_X
; cmp #33
2020-09-29 19:14:21 +00:00
bcc done_mb2_adjust
2020-10-11 14:35:06 +00:00
; lda #33
; sta DESTINATION_X
2020-09-29 19:14:21 +00:00
2020-09-25 03:33:59 +00:00
done_mb2_adjust:
rts
2020-09-29 19:14:21 +00:00
;================================
;================================
; bar_inside2 check bounds
;================================
;================================
bar_inside2_check_bounds:
; just make Y always 20
2020-09-25 03:33:59 +00:00
2020-09-29 19:14:21 +00:00
rts
2020-09-25 03:33:59 +00:00
2020-10-20 00:54:47 +00:00
;================================
;================================
; bar inside animations
;================================
;================================
bar_inside2_animate:
lda FRAMEL
and #$10
beq bar2_other_fire
lda #<bar2_fire1_sprite
sta INL
lda #>bar2_fire1_sprite
jmp bar2_draw_fire
bar2_other_fire:
lda #<bar2_fire2_sprite
sta INL
lda #>bar2_fire2_sprite
bar2_draw_fire:
sta INH
lda #25
sta XPOS
lda #22
sta YPOS
jsr put_sprite_crop
lda FRAMEL
2020-10-20 15:31:58 +00:00
and #$60
2020-10-20 00:54:47 +00:00
beq bar2_other_arm
lda #<bar2_pirate_mug1_sprite
sta INL
lda #>bar2_pirate_mug1_sprite
jmp bar2_draw_arm
bar2_other_arm:
lda #<bar2_pirate_mug2_sprite
sta INL
lda #>bar2_pirate_mug2_sprite
bar2_draw_arm:
sta INH
lda #7
sta XPOS
lda #26
sta YPOS
jsr put_sprite_crop
rts
bar2_fire1_sprite:
.byte 2,2
.byte $dA,$AA
.byte $d1,$dd
2020-09-25 03:33:59 +00:00
2020-10-20 00:54:47 +00:00
bar2_fire2_sprite:
.byte 2,2
.byte $AA,$dA
.byte $1d,$dd
2020-09-25 03:33:59 +00:00
2020-10-20 00:54:47 +00:00
bar2_pirate_mug1_sprite:
.byte 3,3
.byte $25,$00,$05
.byte $22,$82,$74
.byte $d2,$8b,$77
2020-09-25 03:33:59 +00:00
2020-10-20 00:54:47 +00:00
bar2_pirate_mug2_sprite:
.byte 3,3
.byte $25,$b7,$75
.byte $62,$26,$84
.byte $d2,$88,$88
2020-09-25 03:33:59 +00:00
2020-09-29 19:14:21 +00:00
;===================================
;===================================
; actions
;===================================
;===================================
;=============================
bar2_door_action:
bar2_door_nothing:
lda #VERB_WALK
sta CURRENT_VERB
rts
;=============================
fireplace_action:
lda CURRENT_VERB
asl
tay
lda fireplace_actions,Y
cmp #$ff
beq fireplace_nothing
sta MESSAGE_L
lda fireplace_actions+1,Y
sta MESSAGE_H
jmp do_display_message
fireplace_nothing:
lda #VERB_WALK
sta CURRENT_VERB
rts
fireplace_actions:
.word $FFFF ; give
.word doesnt_open ; open
.word doesnt_work ; close
.word cant_pick_up ; pick_up
.word fireplace_look ; look_at
.word $FFFF ; talk_to
.word for_what ; use
.word icant_move ; push
.word icant_move ; pull
fireplace_look:
.byte 18,21,"COZY.",0
;=============================
impt_pirate_action:
lda CURRENT_VERB
asl
tay
lda impt_pirate_actions,Y
cmp #$ff
beq impt_pirate_nothing
sta MESSAGE_L
lda impt_pirate_actions+1,Y
sta MESSAGE_H
jmp do_display_message
impt_pirate_nothing:
lda #VERB_WALK
sta CURRENT_VERB
rts
impt_pirate_actions:
.word $FFFF ; give
.word $FFFF ; open
.word $FFFF ; close
.word $FFFF ; pick_up
.word impt_pirate_look ; look_at
.word impt_pirate_look ; talk_to
.word $FFFF ; use
.word $FFFF ; push
.word $FFFF ; pull
impt_pirate_look:
.byte 8,21,"WHAT BE YE WANTIN' BOY?",0
;=============================
curtain_action:
lda CURRENT_VERB
asl
tay
lda curtain_actions,Y
cmp #$ff
beq curtain_nothing
sta MESSAGE_L
lda curtain_actions+1,Y
sta MESSAGE_H
jmp do_display_message
curtain_nothing:
lda #VERB_WALK
sta CURRENT_VERB
rts
curtain_actions:
.word $FFFF ; give
.word doesnt_open ; open
.word doesnt_work ; close
.word cant_pick_up ; pick_up
.word not_special ; look_at
.word $FFFF ; talk_to
.word for_what ; use
.word icant_move ; push
.word icant_move ; pull