rj-action-library/Runtime/Godot/Root.cs

31 lines
435 B
C#
Raw Normal View History

2024-05-04 08:26:16 +00:00
using Godot;
namespace Rokojori
{
public partial class Root:Node
{
private static Root _singleton;
public override void _Ready()
{
_singleton = this;
}
public static SceneTree Tree()
{
return _singleton.GetTree();
}
public static Window Window()
{
return Tree().Root;
}
public static Root Get()
{
var r = Window();
return _singleton;
}
}
}