mirror of
https://github.com/deater/dos33fsprogs.git
synced 2025-08-15 23:27:51 +00:00
ootw: c15: add alien
need to add real AI also fades into the background
This commit is contained in:
12
ootw/laser.s
12
ootw/laser.s
@@ -381,5 +381,15 @@ done_hit_something:
|
|||||||
; rts
|
; rts
|
||||||
|
|
||||||
|
|
||||||
|
;===============
|
||||||
|
; clear lasers
|
||||||
|
;===============
|
||||||
|
clear_lasers:
|
||||||
|
ldx #MAX_LASERS
|
||||||
|
lda #0
|
||||||
|
clear_laser_loop:
|
||||||
|
sta laser_out,X
|
||||||
|
dex
|
||||||
|
bne clear_laser_loop
|
||||||
|
|
||||||
|
rts
|
||||||
|
@@ -141,6 +141,24 @@ ootw_c15_level_init:
|
|||||||
lda #P_STANDING
|
lda #P_STANDING
|
||||||
sta PHYSICIST_STATE
|
sta PHYSICIST_STATE
|
||||||
|
|
||||||
|
; set up aliens
|
||||||
|
|
||||||
|
jsr clear_aliens
|
||||||
|
|
||||||
|
lda #1
|
||||||
|
sta ALIEN_OUT
|
||||||
|
|
||||||
|
lda #1
|
||||||
|
sta alien0_room
|
||||||
|
lda #36
|
||||||
|
sta alien0_x
|
||||||
|
lda #8
|
||||||
|
sta alien0_y
|
||||||
|
lda #A_STANDING
|
||||||
|
sta alien0_state
|
||||||
|
lda #0
|
||||||
|
sta alien0_direction
|
||||||
|
|
||||||
rts
|
rts
|
||||||
|
|
||||||
|
|
||||||
@@ -155,6 +173,8 @@ ootw_c15_setup_room_and_play:
|
|||||||
;==============================
|
;==============================
|
||||||
; each room init
|
; each room init
|
||||||
|
|
||||||
|
jsr clear_lasers
|
||||||
|
|
||||||
lda #0
|
lda #0
|
||||||
sta LEFT_SHOOT_LIMIT
|
sta LEFT_SHOOT_LIMIT
|
||||||
lda #39
|
lda #39
|
||||||
@@ -202,6 +222,24 @@ room1:
|
|||||||
cmp #1
|
cmp #1
|
||||||
bne room2
|
bne room2
|
||||||
|
|
||||||
|
|
||||||
|
;
|
||||||
|
first_shield:
|
||||||
|
lda #0
|
||||||
|
sta FIRST_SHIELD
|
||||||
|
sta shield_count
|
||||||
|
|
||||||
|
lda #1
|
||||||
|
sta shield_out
|
||||||
|
lda #34
|
||||||
|
sta shield_x
|
||||||
|
|
||||||
|
lda #8
|
||||||
|
sta shield_y
|
||||||
|
|
||||||
|
inc SHIELD_OUT
|
||||||
|
|
||||||
|
|
||||||
; reset for animation
|
; reset for animation
|
||||||
lda #0
|
lda #0
|
||||||
sta FOREGROUND_COUNT
|
sta FOREGROUND_COUNT
|
||||||
@@ -463,6 +501,15 @@ c15_no_bg_action:
|
|||||||
|
|
||||||
jsr draw_physicist
|
jsr draw_physicist
|
||||||
|
|
||||||
|
;=====================================
|
||||||
|
; draw alien
|
||||||
|
;=====================================
|
||||||
|
lda ALIEN_OUT
|
||||||
|
beq no_draw_alien
|
||||||
|
|
||||||
|
jsr move_alien
|
||||||
|
jsr draw_alien
|
||||||
|
no_draw_alien:
|
||||||
|
|
||||||
;=====================================
|
;=====================================
|
||||||
; handle gun
|
; handle gun
|
||||||
|
Reference in New Issue
Block a user