예제 #1
0
    public override void OnInspectorGUI()
    {
        PauseCheck pauseCheck = (PauseCheck)target;

        if (DrawDefaultInspector())
        {
        }
        if (GUILayout.Button("pause"))
        {
            pauseCheck.TogglePause();
        }
    }
예제 #2
0
 private void Init()
 {
     if (s_Instance == null)
     {
         s_Instance = this;
         DontDestroyOnLoad(gameObject);
     }
     else
     {
         Destroy(gameObject);
     }
 }