Newer
Older
DungeonShooting / DungeonShooting_Godot / src / framework / ui / UiManager.cs
@lijincheng lijincheng on 6 Mar 2023 432 bytes UI框架接口,还有一个样例

using Godot;

public static partial class UiManager
{
    private static bool _init = false;
    
    public static void Init()
    {
        if (_init)
        {
            return;
        }

        _init = true;
    }

    public static UiBase OpenUi(string resourcePath)
    {
        return null;
    }

    public static T OpenUi<T>(string resourcePath) where T : UiBase
    {
        return (T)OpenUi(resourcePath);
    }
}