예제 #1
0
 private void Awake()
 {
     if (!instance)
     {
         instance = this;
     }
 }
예제 #2
0
    public static void Show()
    {
        if (!Debug.isDebugBuild)
        {
            return;
        }

        if (!instance)
        {
            GameObject obj = new GameObject();
            obj.hideFlags = HideFlags.HideInHierarchy;
            instance      = obj.AddComponent <DebugOnBuild>();
        }

        instance.isVisible = true;
    }