Root nodes join through ModRoot.AddDeferred, so a reload that unloads the mod first never hands Godot a freed node

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
cthangoverandClaude Opus 5.5 committed 2026-10-24 11:29:08 +02:00
1 parent 1220de6c5b
commit 6a12990322
1 file changed
+1 -1
@@ -41,7 +41,7 @@ namespace Mods.CookingWalkTest
// Deferred: сцена ещё не готова; драйвер сам ждёт Boot.IsReady и
// появления CurrentScene, поэтому порядок с загрузкой сцены не важен.
(Godot.Engine.GetMainLoop() as SceneTree)?.Root?.CallDeferred("add_child", new CookingWalkTestDriverNode(timeout));
ModRoot.AddDeferred(new CookingWalkTestDriverNode(timeout));
}
private static float? ParseTimeout(string[] args)