Initial repo
This commit is contained in:
11
Scenes/PlayerLaser.gd
Normal file
11
Scenes/PlayerLaser.gd
Normal file
@@ -0,0 +1,11 @@
|
||||
extends Area2D
|
||||
|
||||
var speed = 1000
|
||||
|
||||
func _physics_process(delta):
|
||||
global_position.y += -speed * delta
|
||||
|
||||
func _on_area_entered(area):
|
||||
if area.is_in_group("enemies"):
|
||||
area.take_damage(1)
|
||||
queue_free()
|
||||
Reference in New Issue
Block a user