Clegg/bat/bat_bullet/bat_bullet.gd
pennyrigate 6a269eb236 clegg
2025-07-19 16:54:36 -04:00

12 lines
284 B
GDScript

extends Node2D
@export var speed = 100.0
@export var direction = 1
var grazed = false
func _physics_process(delta: float) -> void:
position.x += (speed * direction) * delta
func _on_area_2d_body_entered(body: Node2D) -> void:
if !body.is_in_group("player_hitbox"): queue_free()