예제 #1
0
 private void Init(Asda2EquipmentSlots itemType, ItemStatsSlots statSlot, Asda2Profession proffession)
 {
     if (!Asda2ItemMgr.ItemStatsInfos.ContainsKey(proffession))
     {
         Asda2ItemMgr.ItemStatsInfos.Add(proffession,
                                         new Dictionary <ItemStatsSlots, Dictionary <Asda2EquipmentSlots, List <ItemStatsInfo> > >());
     }
     if (!Asda2ItemMgr.ItemStatsInfos[proffession].ContainsKey(statSlot))
     {
         Asda2ItemMgr.ItemStatsInfos[proffession]
         .Add(statSlot, new Dictionary <Asda2EquipmentSlots, List <ItemStatsInfo> >());
     }
     if (!Asda2ItemMgr.ItemStatsInfos[proffession][statSlot].ContainsKey(itemType))
     {
         Asda2ItemMgr.ItemStatsInfos[proffession][statSlot].Add(itemType, new List <ItemStatsInfo>());
     }
     Asda2ItemMgr.ItemStatsInfos[proffession][statSlot][itemType].Add(this);
 }
예제 #2
0
        private void InitByItemType(ItemStatsSlots statSlot, Asda2Profession proffession)
        {
            switch (this.ItemType)
            {
            case Asda2EquipmentSlots.AnyArmor:
                this.Init(Asda2EquipmentSlots.Head, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.Shirt, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.Boots, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.Gloves, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.Pans, statSlot, proffession);
                break;

            case Asda2EquipmentSlots.AnyAvatar:
                this.Init(Asda2EquipmentSlots.AvatarBoots, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.AvatarGloves, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.AvatarHead, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.AvatarPans, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.AvatarShirt, statSlot, proffession);
                break;

            case Asda2EquipmentSlots.Jevelery:
                this.Init(Asda2EquipmentSlots.RightRing, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.LeftRing, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.Nackles, statSlot, proffession);
                break;

            case Asda2EquipmentSlots.AnyAvatarAccecory:
                this.Init(Asda2EquipmentSlots.AvaratRightHead, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.Wings, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.Cape, statSlot, proffession);
                this.Init(Asda2EquipmentSlots.Accessory, statSlot, proffession);
                break;

            default:
                this.Init(this.ItemType, statSlot, proffession);
                break;
            }
        }