Draw functions don't display from instanced scene

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

I’m writing a script with a _draw() function attached to the root node (which is a referenceRect), and have an instance of this scene in my main scene. When I play just the uninstanced scene it draws as expected, but when displaying the main scene with the instanced scene as a child, nothing is drawn, although the _draw() function is executed. (debugged using print()). I checked the documentation but it says nothing about this. Am I doing something wrong?

Code for reference:

extends ReferenceRect

# class member variables go here, for example:
# var a = 2
# var b = "textvar"
var boxPos;
var boxSize;
var font;

func _ready():
	# Called when the node is added to the scene for the first time.
	# Initialization here
	font = get_font("mainFont");

func _process(delta):
#	# Called every frame. Delta is time since last frame.
#	# Update game logic here.
#	pass

func _draw():
	boxPos = self.get_global_position();
	boxSize = self.get_size();

Also, as a side note, is there a way to pass delta to the draw function, or will it automatically inherit it since update() is being called from the _process function?

:bust_in_silhouette: Reply From: Wren

UPDATE: I realized the problem is not that it isnt being drawn but that its being drawn offscreen. I didn’t understand how transformation worked (and actually I still dont really understand how transformations work in relation draw functions) and the draw coordinates were getting multiplied offscreen. (or something)

I’ll figure it out.