mirror of
https://github.com/deater/dos33fsprogs.git
synced 2025-08-15 08:27:41 +00:00
ootw: fine-tune the walking/running a bit
This commit is contained in:
@@ -49,7 +49,7 @@ OOTW_C2: ootw_c2.o
|
|||||||
|
|
||||||
ootw_c2.o: ootw_c2.s \
|
ootw_c2.o: ootw_c2.s \
|
||||||
gr_copy.s gr_fast_clear.s gr_pageflip.s gr_unrle.s gr_putsprite.s \
|
gr_copy.s gr_fast_clear.s gr_pageflip.s gr_unrle.s gr_putsprite.s \
|
||||||
keyboard.s gr_run_sequence.s \
|
keyboard.s gr_run_sequence.s physicist.s \
|
||||||
ootw_graphics/sprites/sprites_physicist.inc \
|
ootw_graphics/sprites/sprites_physicist.inc \
|
||||||
ootw_c2_cage.s ootw_c2_jail.s ootw_c2_intro.s \
|
ootw_c2_cage.s ootw_c2_jail.s ootw_c2_intro.s \
|
||||||
ootw_graphics/cage/ootw_c2_cage.inc \
|
ootw_graphics/cage/ootw_c2_cage.inc \
|
||||||
|
@@ -1,5 +1,7 @@
|
|||||||
;=======================================
|
;=======================================
|
||||||
; Move physicist based on current state
|
; Move physicist based on current state
|
||||||
|
;
|
||||||
|
; TODO: only update on even frames to slow things down?
|
||||||
|
|
||||||
move_physicist:
|
move_physicist:
|
||||||
lda PHYSICIST_STATE
|
lda PHYSICIST_STATE
|
||||||
@@ -17,7 +19,7 @@ move_physicist_walking:
|
|||||||
|
|
||||||
lda GAIT
|
lda GAIT
|
||||||
and #$7
|
and #$7
|
||||||
cmp #$4
|
cmp #$4 ; only walk roughly 1/8 of time
|
||||||
bne no_move_walk
|
bne no_move_walk
|
||||||
|
|
||||||
lda DIRECTION
|
lda DIRECTION
|
||||||
@@ -33,8 +35,13 @@ no_move_walk:
|
|||||||
;======================
|
;======================
|
||||||
; running
|
; running
|
||||||
move_physicist_running:
|
move_physicist_running:
|
||||||
|
; inc GAIT ; cycle through animation
|
||||||
inc GAIT ; cycle through animation
|
inc GAIT ; cycle through animation
|
||||||
inc GAIT ; cycle through animation
|
|
||||||
|
lda GAIT
|
||||||
|
and #$3
|
||||||
|
cmp #$2 ; only run roughly 1/4 of time
|
||||||
|
bne no_move_run
|
||||||
|
|
||||||
lda DIRECTION
|
lda DIRECTION
|
||||||
beq p_run_left
|
beq p_run_left
|
||||||
@@ -43,7 +50,7 @@ move_physicist_running:
|
|||||||
rts
|
rts
|
||||||
p_run_left:
|
p_run_left:
|
||||||
dec PHYSICIST_X ; run left
|
dec PHYSICIST_X ; run left
|
||||||
|
no_move_run:
|
||||||
rts
|
rts
|
||||||
;======================
|
;======================
|
||||||
; standing
|
; standing
|
||||||
|
Reference in New Issue
Block a user