From e9598b88841374301646a7115253ab38ac904e4c Mon Sep 17 00:00:00 2001 From: jacopograndi Date: Fri, 24 Dec 2021 21:10:33 +0100 Subject: working --- scripts/path.gd | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'scripts/path.gd') diff --git a/scripts/path.gd b/scripts/path.gd index bd3b40f..f8c0fb7 100644 --- a/scripts/path.gd +++ b/scripts/path.gd @@ -8,9 +8,6 @@ const dirs = [ var nodes = [] - -func _ready(): - pass # Replace with function body. func next_node (node, dir): var pos : Vector3 = node.transform.origin @@ -59,13 +56,13 @@ func load_nodes (): func hide (): for child in get_children(): - var mesh = child.find_node("MeshInstance") + var mesh = child.get_node("MeshInstance") mesh.visible = false func show (): for child in get_children(): - var mesh = child.find_node("MeshInstance") - mesh.visible = false + var mesh = child.get_node("MeshInstance") + mesh.visible = true # Called every frame. 'delta' is the elapsed time since the previous frame. #func _process(delta): -- cgit v1.2.3-54-g00ecf