mirror of
https://github.com/deater/dos33fsprogs.git
synced 2024-10-21 18:25:48 +00:00
tfv: implement lightning
This commit is contained in:
parent
939cc6236b
commit
7d59dbc84c
@ -700,20 +700,39 @@ treetrunk_loop:
|
|||||||
|
|
||||||
fore_no_forest:
|
fore_no_forest:
|
||||||
|
|
||||||
|
;=============================
|
||||||
; Draw lightning
|
; Draw lightning
|
||||||
; if (map_x==3) {
|
;=============================
|
||||||
; if ((steps&0xf)==0) {
|
|
||||||
; grsim_put_sprite(lightning,25,4);
|
lda MAP_X
|
||||||
; /* Hurt hit points if in range? */
|
cmp #3
|
||||||
|
bne no_lightning
|
||||||
|
|
||||||
|
lda STEPS
|
||||||
|
and #$f
|
||||||
|
bne no_lightning
|
||||||
|
|
||||||
|
lda #>lightning
|
||||||
|
sta INH
|
||||||
|
lda #<lightning
|
||||||
|
sta INL
|
||||||
|
|
||||||
|
lda #25
|
||||||
|
sta XPOS
|
||||||
|
lda #4
|
||||||
|
sta YPOS
|
||||||
|
|
||||||
|
jsr put_sprite ; grsim_put_sprite(lightning,25,4);
|
||||||
|
|
||||||
|
;=============================
|
||||||
|
; Hurt hit points if in range?
|
||||||
|
;=============================
|
||||||
; if ((tfv_x>25) && (tfv_x<30) && (tfv_y<12)) {
|
; if ((tfv_x>25) && (tfv_x<30) && (tfv_y<12)) {
|
||||||
; printf("HIT! %d %d\n\n",steps,hp);
|
; printf("HIT! %d %d\n\n",steps,hp);
|
||||||
; if (hp>11) {
|
; if (hp>11) {
|
||||||
; hp=10;
|
; hp=10;
|
||||||
; }
|
|
||||||
; }
|
|
||||||
; }
|
|
||||||
; }
|
|
||||||
|
|
||||||
|
no_lightning:
|
||||||
|
|
||||||
jsr page_flip
|
jsr page_flip
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user