void ReadRoleData() { DataDBSBagItem.Read(GetDataPath(GTDataKey.Data_BagItems), EDataKeyType.Pos); DataDBSEquip.Read(GetDataPath(GTDataKey.Data_Equips), EDataKeyType.Instance); DataDBSDressEquip.Read(GetDataPath(GTDataKey.Data_DressEquips), EDataKeyType.Pos); DataDBSMoney.Read(GetDataPath(GTDataKey.Data_Moneys), EDataKeyType.Id); DataDBSAction.Read(GetDataPath(GTDataKey.Data_Actions), EDataKeyType.Id); DataDBSSoul.Read(GetDataPath(GTDataKey.Data_Souls), EDataKeyType.Id); DataDBSBagGem.Read(GetDataPath(GTDataKey.Data_BagGems), EDataKeyType.Pos); DataDBSGem.Read(GetDataPath(GTDataKey.Data_Gems), EDataKeyType.Instance); DataDBSDressGem.Read(GetDataPath(GTDataKey.Data_DressGems), EDataKeyType.Pos); DataDBSBagChip.Read(GetDataPath(GTDataKey.Data_BagChips), EDataKeyType.Pos); DataDBSBagFashion.Read(GetDataPath(GTDataKey.Data_BagFashions), EDataKeyType.Pos); DataDBSBagRune.Read(GetDataPath(GTDataKey.Data_BagRunes), EDataKeyType.Pos); DataDBSDressRune.Read(GetDataPath(GTDataKey.Data_DressRunes), EDataKeyType.Pos); DataDBSDressFashion.Read(GetDataPath(GTDataKey.Data_DressFashions), EDataKeyType.Pos); DataDBSRune.Read(GetDataPath(GTDataKey.Data_Runes), EDataKeyType.Instance); DataDBSCopy.Read(GetDataPath(GTDataKey.Data_Copys), EDataKeyType.Id); DataDBSMainChapter.Read(GetDataPath(GTDataKey.Data_MainChapters), EDataKeyType.Id); DataDBSRaid.Read(GetDataPath(GTDataKey.Data_Raid), EDataKeyType.Id); DataDBSPartner.Read(GetDataPath(GTDataKey.Data_Partners), EDataKeyType.Id); DataDBSMount.Read(GetDataPath(GTDataKey.Data_Mounts), EDataKeyType.Id); DataDBSRelics.Read(GetDataPath(GTDataKey.Data_Relics), EDataKeyType.Id); DataDBSPet.Read(GetDataPath(GTDataKey.Data_Pets), EDataKeyType.Id); DataDBSGuide.Read(GetDataPath(GTDataKey.Data_Guides), EDataKeyType.Id); DataDBSThreadTask.Read(GetDataPath(GTDataKey.Data_MainTasks), EDataKeyType.Id); DataDBSBranchTask.Read(GetDataPath(GTDataKey.Data_BranchTasks), EDataKeyType.Id); DataDBSDailyTask.Read(GetDataPath(GTDataKey.Data_DailyTasks), EDataKeyType.Id); }
void DumpRoleData() { DataDBSMoney.Clear(); DataDBSAction.Clear(); DataDBSSoul.Clear(); DataDBSBagItem.Clear(); DataDBSBagGem.Clear(); DataDBSBagChip.Clear(); DataDBSBagRune.Clear(); DataDBSBagFashion.Clear(); DataDBSDressEquip.Clear(); DataDBSDressFashion.Clear(); DataDBSDressGem.Clear(); DataDBSDressRune.Clear(); DataDBSEquip.Clear(); DataDBSGem.Clear(); DataDBSRune.Clear(); DataDBSMainChapter.Clear(); DataDBSCopy.Clear(); DataDBSRaid.Clear(); DataDBSRelics.Clear(); DataDBSMount.Clear(); DataDBSPartner.Clear(); DataDBSPet.Clear(); DataDBSGuide.Clear(); DataDBSThreadTask.Clear(); DataDBSBranchTask.Clear(); DataDBSDailyTask.Clear(); }
public bool DelBagRune(int pos) { XItem item = DataDBSBagRune.GetDataById(pos); if (item == null) { return(false); } DataDBSBagRune.Delete(item.Pos); DataDBSRune.Delete(item.Instance); return(true); }
public void AddNewRune(int instance, int id) { int newPos = GetNewPos(EBagType.RUNE); if (newPos == 0) { return; } XItem item = new XItem(); item.Pos = newPos; item.Instance = instance; item.Pos = newPos; item.Id = id; item.Num = 1; item.PosType = (int)EPosType.BagRune; DataDBSBagRune.Insert(newPos, item); DataDBSRune.Insert(instance, GTDataFactory.CreateRune(id, instance)); }
public int CompareBagRune(XItem x1, XItem x2) { DItem itemDB1 = ReadCfgItem.GetDataById(x1.Id); DItem itemDB2 = ReadCfgItem.GetDataById(x2.Id); if (itemDB1.Quality != itemDB2.Quality) { return(itemDB2.Quality - itemDB1.Quality); } if (itemDB1.Id != itemDB2.Id) { return(itemDB2.Id - itemDB1.Id); } XRune r1 = DataDBSRune.GetDataById(x1.Instance); XRune r2 = DataDBSRune.GetDataById(x2.Instance); if (r1.Level != r2.Level) { return(r2.Level - r1.Level); } return(x1.Instance - x2.Instance); }