From c9cbeb9dd18c4363bd6e724e62001944f4caf35e Mon Sep 17 00:00:00 2001 From: BERTHAUT Florent <florent.berthaut@univ-lille1.fr> Date: Thu, 28 Sep 2023 15:53:50 +0200 Subject: [PATCH] Fixed missing properties in nodes --- core/IvmiNode.gd | 6 ++---- techniques/control/Tunnel/TunnelPreset.gd | 1 + 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/core/IvmiNode.gd b/core/IvmiNode.gd index a53a245..f36be9d 100644 --- a/core/IvmiNode.gd +++ b/core/IvmiNode.gd @@ -13,7 +13,7 @@ var _can_be_selected = true var _can_be_rotated = true var _can_be_moved = true -func _init(): +func _ready(): add_to_group("ivmi_nodes") #add default properties @@ -27,9 +27,7 @@ func _init(): var quat = transform.basis.get_rotation_quaternion() _add_property("quaternion",[quat.w,quat.x,quat.y,quat.z]) _add_property("distance_to_camera", [0]) - - -func _ready(): + #retrieve full name within scene _full_name = String(get_path()).lstrip("/root/") _full_name = _full_name.right(_full_name.find("/")+1) diff --git a/techniques/control/Tunnel/TunnelPreset.gd b/techniques/control/Tunnel/TunnelPreset.gd index b76c80f..0c3a1d4 100644 --- a/techniques/control/Tunnel/TunnelPreset.gd +++ b/techniques/control/Tunnel/TunnelPreset.gd @@ -18,6 +18,7 @@ enum DATA_TYPE {curve,array,string} var tunnel_param_data_script = preload("res://addons/ivmi-builder/techniques/control/Tunnel/TunnelParamData.gd") func _ready() : + super._ready() if _height_curve: _height_curve.connect("changed",Callable(self,"_on_height_curve_changed")) if _color_curve: -- GitLab