Updated pattern for boss; trying to get it to spawn bullets.
This commit is contained in:
parent
caf2bffb0c
commit
e608652170
24 changed files with 606 additions and 28 deletions
17
scenes/boss_bullet.gd
Normal file
17
scenes/boss_bullet.gd
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
extends Node2D
|
||||
|
||||
@export var speed = 150
|
||||
|
||||
func start(pos):
|
||||
position = pos
|
||||
|
||||
func _process(delta):
|
||||
position += transform.x * speed * delta
|
||||
|
||||
func _on_visible_on_screen_notifier_2d_screen_exited():
|
||||
queue_free()
|
||||
|
||||
func _on_area_entered(area):
|
||||
if area.name == "Player":
|
||||
queue_free()
|
||||
area.shield -= 1
|
||||
Loading…
Add table
Add a link
Reference in a new issue