Godot Version
4.2.2
Hi everyone,
it’s about this script:
extends Node2D
func _play_white_flash():
visible = true
get_node ("BackFlashWhite").play()
var tween:Tween = Tween.new()
add_child(tween)
tween.interpolate_property(self, "modulate", ...
Everything worked fine in Godot 3.5.3, but switching to 4.2.2 an error at exporting my project occurs:
Invalid argument for "add_child()" function: argument 1 should be "Node" but is "Tween.
How could this be fixed?
EDIT:
I added a $: add_child($tween)
and this seems to do the trick…