示例#1
0
        protected FindersKeepers.Controller.Enums.ItemQuality Quality()
        {
            try
            {
                double Quality = ItemActor.GetAttribute(Enigma.D3.Enums.AttributeId.ItemQualityLevel);
                RealQuality = (FindersKeepers.Controller.Enums.ItemQuality)Quality;

                if (Quality < 3)
                {
                    return(FindersKeepers.Controller.Enums.ItemQuality.Normal);
                }

                else if (Quality > 2 && Quality < 6)
                {
                    return(FindersKeepers.Controller.Enums.ItemQuality.Magic);
                }
                else if (Quality > 5 && Quality < 9)
                {
                    return(FindersKeepers.Controller.Enums.ItemQuality.Rare);
                }
                else if (Quality > 9)
                {
                    return(FindersKeepers.Controller.Enums.ItemQuality.Legendary);
                }
                return((FindersKeepers.Controller.Enums.ItemQuality)Quality);
            }

            catch {}

            return(FindersKeepers.Controller.Enums.ItemQuality.Invalid);
        }
示例#2
0
 public Item(Enigma.D3.ActorCommonData Item)
 {
     this.ItemActor   = Item;
     this.AncientItem = Item.GetAttribute(AttributeId.AncientRank) == 1;
     ItemQuality      = Quality();
 }