// Token: 0x06001ED6 RID: 7894 RVA: 0x003AF68C File Offset: 0x003AD88C public void UpDateRowItem(GameObject item, int dataIdx, int panelObjectIdx, int panelId) { if (panelObjectIdx < 9) { if (!this.bFindScrollComp[panelObjectIdx]) { this.bFindScrollComp[panelObjectIdx] = true; this.ScrollComp[panelObjectIdx].LineImage = item.transform.GetChild(0).GetComponent <Image>(); this.ScrollComp[panelObjectIdx].HIBtn = item.transform.GetChild(1).GetComponent <UIHIBtn>(); this.ScrollComp[panelObjectIdx].HIBtn.m_Handler = this; this.ScrollComp[panelObjectIdx].LEBtn = item.transform.GetChild(2).GetComponent <UILEBtn>(); this.ScrollComp[panelObjectIdx].LEBtn.m_Handler = this; this.ScrollComp[panelObjectIdx].ItemName = item.transform.GetChild(4).GetComponent <UIText>(); this.ScrollComp[panelObjectIdx].ItemCountText = item.transform.GetChild(5).GetComponent <UIText>(); this.ScrollComp[panelObjectIdx].RankImg = item.transform.GetChild(3).GetComponent <Image>(); this.ScrollComp[panelObjectIdx].RankText = item.transform.GetChild(3).GetChild(0).GetComponent <UIText>(); this.ScrollComp[panelObjectIdx].Btn3 = item.transform.GetChild(6).GetComponent <UIButton>(); this.ScrollComp[panelObjectIdx].Hint3 = item.transform.GetChild(6).GetComponent <UIButtonHint>(); this.ScrollComp[panelObjectIdx].Hint3.m_Handler = this; this.ScrollComp[panelObjectIdx].Hint3.DelayTime = 0.2f; this.PriceStr[panelObjectIdx] = StringManager.Instance.SpawnString(30); this.NameStr[panelObjectIdx] = StringManager.Instance.SpawnString(150); this.RankStr[panelObjectIdx] = StringManager.Instance.SpawnString(30); } if (dataIdx < 0) { return; } ushort num = 1; ushort num2 = 1; byte b = 1; bool flag = false; this.NameStr[panelObjectIdx].Length = 0; this.ScrollComp[panelObjectIdx].HIBtn.m_BtnID2 = panelObjectIdx; if (this.OpenKind == 1 || this.OpenKind == 4) { this.ScrollComp[panelObjectIdx].LineImage.color = new Color32(94, 183, 138, byte.MaxValue); if (this.tmpEquip.EquipKind == 18) { if (this.IsGiftBox(this.BoxID)) { if (dataIdx >= this.tmpGB.ItemData.Length) { return; } num = this.tmpGB.ItemData[dataIdx].ItemID; num2 = this.tmpGB.ItemData[dataIdx].ItemCount; } else { if (dataIdx >= this.tmpLB.ItemData.Length) { return; } num = this.tmpLB.ItemData[dataIdx].ItemID; num2 = this.tmpLB.ItemData[dataIdx].ItemCount; } Equip recordByKey = this.DM.EquipTable.GetRecordByKey(num); flag = this.GM.IsLeadItem(recordByKey.EquipKind); this.NameStr[panelObjectIdx].Append(this.DM.mStringTable.GetStringByID((uint)recordByKey.EquipName)); if (flag) { if (this.EndRank == 0) { this.NameStr[panelObjectIdx].StringToFormat(MallManager.Instance.GetItemRankName(this.BeginRank)); this.NameStr[panelObjectIdx].AppendFormat("({0})"); } else { this.NameStr[panelObjectIdx].StringToFormat(MallManager.Instance.GetItemRankName(this.BeginRank)); this.NameStr[panelObjectIdx].StringToFormat(MallManager.Instance.GetItemRankName(this.EndRank)); this.NameStr[panelObjectIdx].AppendFormat(this.DM.mStringTable.GetStringByID(7738u)); } } if (recordByKey.EquipKind == 30) { PetTbl recordByKey2 = PetManager.Instance.PetTable.GetRecordByKey(recordByKey.SyntheticParts[0].SyntheticItem); this.RankStr[panelObjectIdx].Length = 0; StringManager.IntToStr(this.RankStr[panelObjectIdx], (long)recordByKey2.Rare, 1, false); this.ScrollComp[panelObjectIdx].RankText.text = this.RankStr[panelObjectIdx].ToString(); this.ScrollComp[panelObjectIdx].RankText.SetAllDirty(); this.ScrollComp[panelObjectIdx].RankText.cachedTextGenerator.Invalidate(); this.ScrollComp[panelObjectIdx].RankImg.gameObject.SetActive(true); } else { this.ScrollComp[panelObjectIdx].RankImg.gameObject.SetActive(false); } } else { if (this.tmpEquip.EquipKind != 19) { return; } if (dataIdx >= this.tmpCB.ItemData.Length) { return; } num = this.tmpCB.ItemData[dataIdx].ItemID; num2 = this.tmpCB.ItemData[dataIdx].ItemCount; b = this.tmpCB.ItemData[dataIdx].Rank; Equip recordByKey = this.DM.EquipTable.GetRecordByKey(num); flag = this.GM.IsLeadItem(recordByKey.EquipKind); if (this.tmpCB.ItemData[dataIdx].Rank != 0) { this.NameStr[panelObjectIdx].StringToFormat(MallManager.Instance.GetItemRankName(this.tmpCB.ItemData[dataIdx].Rank)); this.NameStr[panelObjectIdx].AppendFormat(this.DM.mStringTable.GetStringByID(7739u)); } else if (recordByKey.EquipKind == 18 && this.tmpEquip.PropertiesInfo[0].Propertieskey != 6) { byte itemRank = 1; if (this.tmpEquip.PropertiesInfo[0].Propertieskey == 1) { itemRank = 3; } else if (this.tmpEquip.PropertiesInfo[0].Propertieskey == 2) { itemRank = 4; } else if (this.tmpEquip.PropertiesInfo[0].Propertieskey == 3) { itemRank = 5; } this.NameStr[panelObjectIdx].StringToFormat(MallManager.Instance.GetItemRankName(itemRank)); this.NameStr[panelObjectIdx].AppendFormat(this.DM.mStringTable.GetStringByID(7739u)); } this.NameStr[panelObjectIdx].Append(this.DM.mStringTable.GetStringByID((uint)recordByKey.EquipName)); } } else if (this.OpenKind == 2) { this.ScrollComp[panelObjectIdx].LineImage.color = new Color32(94, 165, 183, byte.MaxValue); if (dataIdx >= this.GM.CommonItemData.Count) { return; } num = this.GM.CommonItemData[dataIdx].ItemID; num2 = this.GM.CommonItemData[dataIdx].Num; b = this.GM.CommonItemData[dataIdx].ItemRank; Equip recordByKey = this.DM.EquipTable.GetRecordByKey(num); flag = this.GM.IsLeadItem(recordByKey.EquipKind); if (this.GM.CommonItemData[dataIdx].ItemRank != 0) { this.NameStr[panelObjectIdx].StringToFormat(MallManager.Instance.GetItemRankName(b)); this.NameStr[panelObjectIdx].AppendFormat(this.DM.mStringTable.GetStringByID(7739u)); } CString cstring = StringManager.Instance.StaticString1024(); UIItemInfo.SetNameProperties(null, null, cstring, null, ref recordByKey, null); this.NameStr[panelObjectIdx].Append(cstring); } else if (this.OpenKind == 3) { this.ScrollComp[panelObjectIdx].LineImage.color = new Color32(94, 165, 183, byte.MaxValue); MerchantmanManager instance = MerchantmanManager.Instance; if (dataIdx >= (int)instance.MerchantmanExtraData.DataLen) { return; } num = instance.MerchantmanExtraData.ItemContain[dataIdx].ItemID; num2 = instance.MerchantmanExtraData.ItemContain[dataIdx].Num; b = instance.MerchantmanExtraData.ItemContain[dataIdx].ItemRank; Equip recordByKey = this.DM.EquipTable.GetRecordByKey(num); flag = this.GM.IsLeadItem(recordByKey.EquipKind); if (b != 0) { this.NameStr[panelObjectIdx].StringToFormat(MallManager.Instance.GetItemRankName(b)); this.NameStr[panelObjectIdx].AppendFormat(this.DM.mStringTable.GetStringByID(7739u)); } CString cstring2 = StringManager.Instance.StaticString1024(); UIItemInfo.SetNameProperties(null, null, cstring2, null, ref recordByKey, null); this.NameStr[panelObjectIdx].Append(cstring2); } if (flag) { GUIManager.Instance.ChangeLordEquipImg(this.ScrollComp[panelObjectIdx].LEBtn.transform, num, b, eLordEquipDisplayKind.OnlyItem, 0, 0, 0, 0, 0, false); } else { GUIManager.Instance.ChangeHeroItemImg(this.ScrollComp[panelObjectIdx].HIBtn.transform, eHeroOrItem.Item, num, 0, 0, 0); } this.ScrollComp[panelObjectIdx].LEBtn.gameObject.SetActive(flag); this.ScrollComp[panelObjectIdx].HIBtn.gameObject.SetActive(!flag); this.ScrollComp[panelObjectIdx].Hint3.Parm1 = num; this.ScrollComp[panelObjectIdx].Hint3.Parm2 = b; if (flag || (!MallManager.Instance.CheckCanOpenDetail(num) && !PetManager.Instance.IsFakePetItem(num))) { this.ScrollComp[panelObjectIdx].Hint3.enabled = true; } else { this.ScrollComp[panelObjectIdx].Hint3.enabled = false; } this.ScrollComp[panelObjectIdx].Btn3.gameObject.SetActive(this.ScrollComp[panelObjectIdx].Hint3.enabled); this.ScrollComp[panelObjectIdx].ItemName.text = this.NameStr[panelObjectIdx].ToString(); this.ScrollComp[panelObjectIdx].ItemName.SetAllDirty(); this.ScrollComp[panelObjectIdx].ItemName.cachedTextGenerator.Invalidate(); this.PriceStr[panelObjectIdx].Length = 0; StringManager.IntToStr(this.PriceStr[panelObjectIdx], (long)num2, 1, true); this.ScrollComp[panelObjectIdx].ItemCountText.text = this.PriceStr[panelObjectIdx].ToString(); this.ScrollComp[panelObjectIdx].ItemCountText.SetAllDirty(); this.ScrollComp[panelObjectIdx].ItemCountText.cachedTextGenerator.Invalidate(); } }
// Token: 0x06001ED7 RID: 7895 RVA: 0x003B0230 File Offset: 0x003AE430 public void ButtonOnClick(GameObject gameObject, int dataIndex, int panelId) { if (dataIndex < 0) { return; } ushort tmpItemID = 1; if (this.OpenKind == 1 || this.OpenKind == 4) { if (this.tmpEquip.EquipKind == 18) { if (this.IsGiftBox(this.BoxID)) { if (dataIndex >= this.tmpGB.ItemData.Length) { return; } tmpItemID = this.tmpGB.ItemData[dataIndex].ItemID; } else { if (dataIndex >= this.tmpLB.ItemData.Length) { return; } tmpItemID = this.tmpLB.ItemData[dataIndex].ItemID; } } else { if (this.tmpEquip.EquipKind != 19) { return; } if (dataIndex >= this.tmpCB.ItemData.Length) { return; } tmpItemID = this.tmpCB.ItemData[dataIndex].ItemID; } } else if (this.OpenKind == 2) { if (dataIndex >= this.GM.CommonItemData.Count) { return; } tmpItemID = this.GM.CommonItemData[dataIndex].ItemID; } else if (this.OpenKind == 3) { MerchantmanManager instance = MerchantmanManager.Instance; if (dataIndex >= (int)instance.MerchantmanExtraData.DataLen) { return; } tmpItemID = instance.MerchantmanExtraData.ItemContain[dataIndex].ItemID; } if (this.OpenNext(tmpItemID)) { AudioManager.Instance.PlayUISFXIndex(UIClickSoundIndex.Normal); } }
// Token: 0x06001ED4 RID: 7892 RVA: 0x003AE6E0 File Offset: 0x003AC8E0 private void RefreshList(byte Kind, ushort ItemID) { this.SetIndex = 0; this.OpenKind = Kind; this.OpenID = (this.BoxID = ItemID); this.ForgeBtn.SetActive(false); this.FBGO.SetActive(false); if (this.OpenKind == 1 || this.OpenKind == 4) { ushort inKey = ItemID; if (this.OpenKind == 4) { ItemID = (this.BoxID = DataManager.FBMissionDataManager.FBMissionTable.GetRecordByKey(inKey).FriendPrice); } this.TitleImage1.SetActive(true); this.RTImage1.enabled = true; this.GetAllText2.gameObject.SetActive(false); this.BackImage.color = new Color32(42, 185, 109, byte.MaxValue); this.tmpEquip = this.DM.EquipTable.GetRecordByKey(ItemID); this.NowHeightList.Clear(); if (this.tmpEquip.EquipKind == 18) { if (this.tmpEquip.PropertiesInfo[0].Propertieskey == 1) { this.BeginRank = 1; this.EndRank = 3; } else if (this.tmpEquip.PropertiesInfo[0].Propertieskey == 2) { this.BeginRank = 2; this.EndRank = 4; } else if (this.tmpEquip.PropertiesInfo[0].Propertieskey == 3) { this.BeginRank = 1; this.EndRank = 5; } else if (this.tmpEquip.PropertiesInfo[0].Propertieskey == 4) { this.BeginRank = (byte)this.tmpEquip.PropertiesInfo[5].Propertieskey; this.EndRank = (byte)this.tmpEquip.PropertiesInfo[5].PropertiesValue; } else if (this.tmpEquip.PropertiesInfo[0].Propertieskey == 5) { this.GetAllText2.gameObject.SetActive(true); this.RTImage1.enabled = false; this.RTImage2.enabled = true; this.BeginRank = 0; this.EndRank = 0; } else { this.BeginRank = 0; this.EndRank = 0; } this.TitleStr.Length = 0; if (this.tmpEquip.PropertiesInfo[0].PropertiesValue == 0) { this.TitleStr.StringToFormat(MallManager.Instance.GetItemRankName(this.EndRank)); this.TitleStr.AppendFormat(this.DM.mStringTable.GetStringByID(7739u)); } this.TitleStr.Append(this.DM.mStringTable.GetStringByID((uint)this.tmpEquip.EquipName)); this.TitleNameText.text = this.TitleStr.ToString(); this.TitleNameText.SetAllDirty(); this.TitleNameText.cachedTextGenerator.Invalidate(); if (this.IsGiftBox(this.BoxID)) { this.tmpGB = this.DM.GiftBoxTable.GetRecordByKey(this.tmpEquip.PropertiesInfo[1].Propertieskey); this.ItemCount = 0; for (int i = 0; i < this.tmpGB.ItemData.Length; i++) { if (this.tmpGB.ItemData[i].ItemID != 0) { this.ItemCount++; this.NowHeightList.Add(60f); } } } else { this.tmpLB = this.DM.LotteryBoxTable.GetRecordByKey(this.tmpEquip.PropertiesInfo[1].Propertieskey); this.SetIndex = this.tmpLB.SetIndex; if (this.SetIndex != 0) { this.ForgeBtn.SetActive(true); } this.ItemCount = 0; for (int j = 0; j < this.tmpLB.ItemData.Length; j++) { if (this.tmpLB.ItemData[j].ItemID != 0) { this.ItemCount++; this.NowHeightList.Add(60f); } } } this.GetAllText.text = this.DM.mStringTable.GetStringByID(837u); this.GetAllText.color = this.GatOneColor; } else if (this.tmpEquip.EquipKind == 19) { this.TitleNameText.text = this.DM.mStringTable.GetStringByID((uint)this.tmpEquip.EquipName); this.tmpCB = this.DM.ComboBoxTable.GetRecordByKey(this.tmpEquip.PropertiesInfo[1].Propertieskey); this.SetIndex = this.tmpCB.SetIndex; if (this.SetIndex != 0) { this.ForgeBtn.SetActive(true); } this.ItemCount = 0; for (int k = 0; k < this.tmpCB.ItemData.Length; k++) { if (this.tmpCB.ItemData[k].ItemID != 0) { this.ItemCount++; this.NowHeightList.Add(60f); } } this.GetAllText.text = this.DM.mStringTable.GetStringByID(838u); this.GetAllText.color = this.GatAllColor; } if (this.OpenKind == 4) { this.GetAllText.text = this.DM.mStringTable.GetStringByID(12190u); this.GetAllText.color = this.GatAllColor; FBMissionTbl recordByKey = DataManager.FBMissionDataManager.FBMissionTable.GetRecordByKey(inKey); Equip recordByKey2 = this.DM.EquipTable.GetRecordByKey(recordByKey.OwnPrice); ComboBox recordByKey3 = this.DM.ComboBoxTable.GetRecordByKey(recordByKey2.PropertiesInfo[1].Propertieskey); int num = 0; while (num < 4 && num < recordByKey3.ItemData.Length) { if (recordByKey3.ItemData[num].ItemID != 0) { Equip recordByKey4 = this.DM.EquipTable.GetRecordByKey(recordByKey3.ItemData[num].ItemID); bool flag = this.GM.IsLeadItem(recordByKey4.EquipKind); ushort itemID = recordByKey3.ItemData[num].ItemID; ushort itemCount = recordByKey3.ItemData[num].ItemCount; byte rank = this.tmpCB.ItemData[num].Rank; if (flag) { GUIManager.Instance.ChangeLordEquipImg(this.FBLEBtn[num].transform, itemID, rank, eLordEquipDisplayKind.OnlyItem, 0, 0, 0, 0, 0, false); } else { GUIManager.Instance.ChangeHeroItemImg(this.FBHIBtn[num].transform, eHeroOrItem.Item, itemID, 0, 0, 0); } this.FBHIBtn[num].gameObject.SetActive(!flag); this.FBLEBtn[num].gameObject.SetActive(flag); this.FBCountStr[num].Length = 0; this.FBCountStr[num].IntToFormat((long)itemCount, 1, false); if (this.GM.IsArabic) { this.FBCountStr[num].AppendFormat("{0}x"); } else { this.FBCountStr[num].AppendFormat("x{0}"); } this.FBCountText[num].text = this.FBCountStr[num].ToString(); this.FBCountText[num].SetAllDirty(); this.FBCountText[num].cachedTextGenerator.Invalidate(); this.FBItemGO[num].SetActive(true); } else { this.FBItemGO[num].SetActive(false); } num++; } this.FBGO.SetActive(true); } } else if (this.OpenKind == 2) { this.TitleImage2.SetActive(true); this.BackImage.color = new Color32(42, 150, 185, byte.MaxValue); this.tmpEquip = this.DM.EquipTable.GetRecordByKey(ItemID); this.TitleStr.Length = 0; if (this.tmpEquip.EquipKind == 18) { if (this.tmpEquip.PropertiesInfo[0].Propertieskey == 1) { this.BeginRank = 1; this.EndRank = 3; } else if (this.tmpEquip.PropertiesInfo[0].Propertieskey == 2) { this.BeginRank = 2; this.EndRank = 4; } else if (this.tmpEquip.PropertiesInfo[0].Propertieskey == 3) { this.BeginRank = 1; this.EndRank = 5; } else if (this.tmpEquip.PropertiesInfo[0].Propertieskey == 4) { this.BeginRank = (byte)this.tmpEquip.PropertiesInfo[5].Propertieskey; this.EndRank = (byte)this.tmpEquip.PropertiesInfo[5].PropertiesValue; } else { this.BeginRank = 0; this.EndRank = 0; } if (this.tmpEquip.PropertiesInfo[0].PropertiesValue == 0) { this.TitleStr.StringToFormat(MallManager.Instance.GetItemRankName(this.EndRank)); this.TitleStr.AppendFormat(this.DM.mStringTable.GetStringByID(7739u)); } } this.TitleStr.Append(this.DM.mStringTable.GetStringByID((uint)this.tmpEquip.EquipName)); this.TitleStr.Append(' '); this.TitleStr.IntToFormat((long)this.GM.OpenBoxCount, 1, false); if (this.GM.IsArabic) { this.TitleStr.AppendFormat("{0}x"); } else { this.TitleStr.AppendFormat("x{0}"); } this.TitleNameText.text = this.TitleStr.ToString(); this.TitleNameText.SetAllDirty(); this.TitleNameText.cachedTextGenerator.Invalidate(); this.NowHeightList.Clear(); this.ItemCount = this.GM.CommonItemData.Count; for (int l = 0; l < this.ItemCount; l++) { this.NowHeightList.Add(60f); } this.GetAllText.text = this.DM.mStringTable.GetStringByID(839u); this.GetAllText.color = this.GatAllColor; } else if (this.OpenKind == 3) { this.TitleImage1.SetActive(true); this.RTImage1.enabled = true; this.BackImage.color = new Color32(42, 185, 109, byte.MaxValue); this.tmpEquip = this.DM.EquipTable.GetRecordByKey(ItemID); this.NowHeightList.Clear(); this.TitleNameText.text = this.DM.mStringTable.GetStringByID((uint)this.tmpEquip.EquipName); MerchantmanManager instance = MerchantmanManager.Instance; this.ItemCount = 0; for (int m = 0; m < (int)instance.MerchantmanExtraData.DataLen; m++) { if (instance.MerchantmanExtraData.ItemContain[m].ItemID != 0) { this.ItemCount++; this.NowHeightList.Add(60f); } } this.GetAllText.text = this.DM.mStringTable.GetStringByID(838u); this.GetAllText.color = this.GatAllColor; if (instance.bNeedUpDateExtra) { instance.SendReQusetBlackMarket_Data(); } } this.GM.ChangeHeroItemImg(this.m_transform.GetChild(5), eHeroOrItem.Item, this.BoxID, 0, 0, 0); this.Scroll.AddNewDataHeight(this.NowHeightList, true, true); }