コード例 #1
0
 static public UIMoveToPoint Get(GameObject go)
 {
     if (go == null)
     {
         Debug.LogError("EventTriggerListener_go_is_NULL");
         return null;
     }
     else
     {
         UIMoveToPoint listener = go.GetComponent<UIMoveToPoint>();
         if (listener == null) listener = go.AddComponent<UIMoveToPoint>();
         return listener;
     }
 }
コード例 #2
0
ファイル: UIMoveToPoint.cs プロジェクト: atom-chen/rongyaojt
        public static UIMoveToPoint Get(GameObject go)
        {
            bool          flag = go == null;
            UIMoveToPoint result;

            if (flag)
            {
                Debug.LogError("EventTriggerListener_go_is_NULL");
                result = null;
            }
            else
            {
                UIMoveToPoint uIMoveToPoint = go.GetComponent <UIMoveToPoint>();
                bool          flag2         = uIMoveToPoint == null;
                if (flag2)
                {
                    uIMoveToPoint = go.AddComponent <UIMoveToPoint>();
                }
                result = uIMoveToPoint;
            }
            return(result);
        }