コード例 #1
0
ファイル: WebTool.cs プロジェクト: ckhongme/LibForUnityCode
 private void Awake()
 {
     if (instance == null)
     {
         instance = this;
     }
     else if (instance != this)
     {
         DestroyImmediate(gameObject);
     }
 }
コード例 #2
0
ファイル: WebTool.cs プロジェクト: ckhongme/LibForUnityCode
 private void OnDestroy()
 {
     instance = null;
 }