small racing game im working on
Diffstat (limited to 'race.gd')
-rw-r--r--race.gd4
1 files changed, 1 insertions, 3 deletions
diff --git a/race.gd b/race.gd
index a3ecf55..16b2a36 100644
--- a/race.gd
+++ b/race.gd
@@ -34,9 +34,7 @@ func _init(t: TrackResource, _car_scene, _ghost_scene, _track_loader_scene) -> v
track_res = t
func mkghost() -> void:
- var g: Node3D = ghost_scene.instantiate()
- g.set_script(load("res://classes/ghost.gd"))
- ghost = g
+ ghost = ghost_scene.instantiate()
add_child(ghost)
reset_ghost()
created_ghost.emit(ghost)