I have made a world scene that includes a model planetarium in which the model sun moves in synchronization with the DirectionalLight3D that is lighting the scene, using this simple script attached to the model sun:
extends Node3D
@export var target: Node3D
func _process(delta):
global_rotation=target.global_rotation
This gives me a field in the Inspector that lets me assign a target for the model to synchronize its rotation value with.
Now I want to make the whole model planetarium it’s own scene with “Save Branch as Scene…”. But when I do that, the script in the “model scene” can no longer target an object in the “world scene”. The field in the inspector only lets me pick from nodes that are in the same scene.
What would be the best way to do to link the model sun in the model scene with the DirectLight3D in the world scene?