GMTKGameJam2024/scripts/fireparticles.gd

15 lines
428 B
GDScript3
Raw Normal View History

2024-08-18 23:21:19 +01:00
@tool
extends Node3D
# Called when the node enters the scene tree for the first time.
func _ready() -> void:
pass # Replace with function body.
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta: float) -> void:
var camera = get_viewport().get_camera_3d()
if camera == null: return
$smoke.set_global_rotation(get_global_rotation().direction_to(camera.get_global_position()))