Beispiel #1
0
 public void ItemButton()
 {
     UnityEngine.GameObject go = UIManager.Instance.GetWindowGoByName("GamePokey");
     if (go != null)
     {
         if (!NGUITools.GetActive(go))
         {
             ArkCrossEngine.ItemConfig itemconfig = ArkCrossEngine.LogicSystem.GetItemDataById(id);
             if (itemconfig != null)
             {
                 EquipmentInfo ei = GamePokeyManager.GetEquipmentInfo(itemconfig.m_WearParts);
                 if (ei != null)
                 {
                     go = UIManager.Instance.GetWindowGoByName("ItemProperty");
                     if (go != null && !NGUITools.GetActive(go))
                     {
                         ItemProperty ip = go.GetComponent <ItemProperty>();
                         if (ip != null)
                         {
                             ip.Compare(ei.id, ei.level, ei.propertyid, id, ei.level, propertyid, itemconfig.m_WearParts);
                             UIManager.Instance.ShowWindowByName("ItemProperty");
                         }
                     }
                 }
             }
         }
         else
         {
             UIManager.Instance.HideWindowByName("ItemProperty");
         }
     }
 }
Beispiel #2
0
 public void OnButtonClick()
 {
     UnityEngine.GameObject gogo = UIManager.Instance.GetWindowGoByName("GamePokey");
     if (gogo != null)
     {
         UnityEngine.Transform tf = gogo.transform.Find("RoleInfo");
         if (tf != null)
         {
             if (NGUITools.GetActive(tf.gameObject))
             {
                 return;
             }
         }
     }
     ArkCrossEngine.ItemConfig itemconfig = ArkCrossEngine.LogicSystem.GetItemDataById(ID);
     if (itemconfig != null)
     {
         UnityEngine.GameObject go = UIManager.Instance.GetWindowGoByName("GamePokey");
         if (go != null)
         {
             EquipmentInfo ei = GamePokeyManager.GetEquipmentInfo(itemconfig.m_WearParts);
             if (ei != null)
             {
                 go = UIManager.Instance.GetWindowGoByName("ItemProperty");
                 if (go != null && !NGUITools.GetActive(go))
                 {
                     ItemProperty ip = go.GetComponent <ItemProperty>();
                     if (ip != null)
                     {
                         ip.Compare(ei.id, ei.level, ei.propertyid, ID, ei.level, PropertyId, itemconfig.m_WearParts);
                         UIManager.Instance.ShowWindowByName("ItemProperty");
                     }
                 }
             }
         }
     }
 }