Logging and errors
Use GD.print to send messages to both the terminal and Godot's Output panel. Kotlin and Scala's println and Java's System.out.println write to standard output only.
1 | |
1 | |
1 | |
Use GD.pushError and GD.pushWarning to report a diagnostic to Godot's debugger:
1 2 | |
1 2 | |
1 2 | |
Exceptions do not stop the game
An exception escaping a JVM callback is logged with its stack trace. The Godot-side call returns a default value and the game keeps running. Statements after the throw in that callback do not run.