I am trying to close a Node2d based dialog by hiding it via touch screen button (which is a child of this dialog via another Node2d). I use the following code:
$SettingsOKButtonSound.stream = positiveSound
settingsOKButtonLight.enabled = false
settingsOKButtonLightBlob.visible = false
var settingsDialog = gettree().getnodesin_group("SettingsDialog")
if (settingsDialog.visible == true):
settingsDialog.visible = false
when this code is executed I get 4 error messages of the same kind:
E 0:00:40.730 input: Condition "!isvisibleintree()" is true.
<C++-Quellcode>scene/2d/touchscreenbutton.cpp:201 @ _input()
Code still works but i would like to get rid of the annoying messages.
Is there any solution?