How do I access variables in an instanced sub-scene using script

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By jasperbrooks79

I have my enemies in a separate scene, but I can’t make them change color, from the main scene . . how does one access stuff in instanced sub-scenes, using visual script, I just want them to ’ blink ’ red, when they are hit . . :(( Thx

:bust_in_silhouette: Reply From: Loxyrak

If you have 2 scripts/nodes, for exemple, and

You can access another script by using a var like so.

var target = get_node(“/root/MainScene/Player”)

yes, but I want to access something, in an instanced sub-scene, not just another node, in the SAME scene, thx . . .

jasperbrooks79 | 2020-08-01 01:47