示例#1
0
		void OnEnable()
		{
			if (m_cNavMono == null)
			{
				if (target)
				{
					m_cNavMono = (NavMonoEditor)target;
				}
				else
					Debug.Log("需要一个脚本对象,必须挂载脚本上面");
			}
			if( m_cParent == null )
			{
				GameObject.DestroyImmediate(GameObject.Find("NavMeshParent"));
				m_cParent = new GameObject("NavMeshParent");
				m_cParent.transform.parent = this.m_cNavMono.transform;
			}
		}
示例#2
0
 void OnEnable()
 {
     if (m_cNavMono == null)
     {
         if (target)
         {
             m_cNavMono = (NavMonoEditor)target;
         }
         else
         {
             Debug.Log("需要一个脚本对象,必须挂载脚本上面");
         }
     }
     if (m_cParent == null)
     {
         GameObject.DestroyImmediate(GameObject.Find("NavMeshParent"));
         m_cParent = new GameObject("NavMeshParent");
         m_cParent.transform.parent = this.m_cNavMono.transform;
     }
 }
示例#3
0
 void OnDestroy()
 {
     this.m_cNavMono = null;
 }
示例#4
0
		void OnDestroy()
		{
			this.m_cNavMono = null;
		}