summaryrefslogtreecommitdiff
path: root/client
diff options
context:
space:
mode:
Diffstat (limited to 'client')
-rw-r--r--client/Root.cs14
1 files changed, 13 insertions, 1 deletions
diff --git a/client/Root.cs b/client/Root.cs
index e39a485..b565083 100644
--- a/client/Root.cs
+++ b/client/Root.cs
@@ -13,7 +13,19 @@ public partial class Root : Node2D
public unsafe override void _Ready()
{
RenderingServer.SetDefaultClearColor(Colors.LightGray);
-
+ LibDjup.log_set_output((level, source, line, msg) => {
+ string level_name = level switch
+ {
+ LogLevel.Trace => "trace",
+ LogLevel.Debug => "debug",
+ LogLevel.Info => "info",
+ LogLevel.Warn => "warn",
+ LogLevel.Error => "error",
+ LogLevel.Fatal => "fatal"
+ };
+ GD.Print($"libdjup {source}:{line} {level_name.PadLeft(5, ' ')}: {msg}");
+ });
+
native_world = LibDjup.world_create();
for (int i = 0; i < balls.Length; i++)
{