Fix ViewportTexture error when viewport is used from a child scene
Fix ViewportTexture error when viewport is used from a child scene

Fix invalid errors when a separate child scene file contains a viewport and
that viewport is used for a texture in the current scene.

Fixes #27790.

ex/godot,ex/godot,ex/godot,ex/godot,ex/godot,ex/godot,ex/godot,ex/godot