示例#1
0
 public static bool IsLegwear(this ItemSpec item)
 {
     return(item.CanBeWornOnLocation(ArmourWearLocation.Legs));
 }
示例#2
0
 public static string GetDescription(this ItemSpec item)
 {
     return(item.GetProperty(ItemSpecPropertyEnum.Description).StringValue);
 }
示例#3
0
        public static void SetDurabilityMax(this ItemSpec item, short value)
        {
            var spec = new ItemSpecProperty((short)ItemSpecPropertyEnum.DurabilityMax, value);

            item.SetProperty(spec);
        }
示例#4
0
 public static void SetResourceType(this ItemSpec item, ResourceType resource)
 {
     item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.ResouceType, (short)resource));
 }
示例#5
0
        /**/
        public static string GetImageName(this ItemSpec item)
        {
            return(item.GetProperty(ItemSpecPropertyEnum.ImageName).StringValue);
        }

        public static void SetImageName(this ItemSpec item, string value)
        {
            var spec = new ItemSpecProperty((short)ItemSpecPropertyEnum.ImageName, value);

            item.SetProperty(spec);
        }

        /**/
        public static int GetCost(this ItemSpec item)
        {
            return(item.GetProperty(ItemSpecPropertyEnum.Cost).IntValue);
        }
示例#6
0
        public static void SetModelName(this ItemSpec item, string value)
        {
            var spec = new ItemSpecProperty((short)ItemSpecPropertyEnum.ModelName, value);

            item.SetProperty(spec);
        }
示例#7
0
 public static void SetWeaponNoiseDistance(this ItemSpec item, float value)
 {
     item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.NoiseRange, value));
 }
示例#8
0
 public static short GetReloadClipSize(this ItemSpec item)
 {
     return(item.GetProperty(ItemSpecPropertyEnum.ReloadClipSize).ShortValue);
 }
示例#9
0
 public static void SetReloadClipSize(this ItemSpec item, short size)
 {
     item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.ReloadClipSize, size));
 }
示例#10
0
 public static void SetMeleeRange(this ItemSpec item, float value)
 {
     item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.MeleeRange, value));
 }
示例#11
0
 public static void SetClipSize(this ItemSpec item, short value)
 {
     item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.ClipSize, value));
 }
示例#12
0
 /****/
 public static float GetMeleeRange(this ItemSpec item)
 {
     return(item.GetProperty(ItemSpecPropertyEnum.MeleeRange).FloatValue);
 }
示例#13
0
 public static void SetWeaponDelay(this ItemSpec item, uint value)
 {
     item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.UsageDelay, (int)value));
 }
示例#14
0
 public static bool IsFootwear(this ItemSpec item)
 {
     return(item.CanBeWornOnLocation(ArmourWearLocation.Feet));
 }
示例#15
0
        public static void SetHungerReduceAmount(this ItemSpec item, short value)
        {
            var spec = new ItemSpecProperty((short)ItemSpecPropertyEnum.HungerReduceAmount, value);

            item.SetProperty(spec);
        }
示例#16
0
 /****/
 public static float GetBulletSpread(this ItemSpec item)
 {
     return(item.GetProperty(ItemSpecPropertyEnum.BulletSpread).FloatValue);
 }
示例#17
0
 public static void SetHealAmount(this ItemSpec item, short value)
 {
     item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.HealAmount, value));
 }
示例#18
0
 public static void SetBulletSpread(this ItemSpec item, float value)
 {
     item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.BulletSpread, value));
 }
示例#19
0
 public static bool IsHealthPack(this ItemSpec item)
 {
     return(item.GetHealAmount() > 0 &&
            item.IsWeapon() == false);
 }
示例#20
0
 public static float GetDamageMax(this ItemSpec item)
 {
     return(item.GetProperty(ItemSpecPropertyEnum.DamageMax).FloatValue);
 }
示例#21
0
 public static void SetDefenceMultipliers(this ItemSpec item, Dictionary <DamageTypeEnum, float> multipliers)
 {
     item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.DefenceValues, multipliers));
 }
示例#22
0
        /**/
        public static string GetName(this ItemSpec item)
        {
            return(item.GetProperty(ItemSpecPropertyEnum.Name).StringValue);
        }

        public static void SetName(this ItemSpec item, string value)
        {
            var spec = new ItemSpecProperty((short)ItemSpecPropertyEnum.Name, value);

            item.SetProperty(spec);
        }

        /**/
        public static string GetModelName(this ItemSpec item)
        {
            return(item.GetProperty(ItemSpecPropertyEnum.ModelName).StringValue);
        }
示例#23
0
 public static void SetResourceAmount(this ItemSpec item, byte amount)
 {
     item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.ResourceAmount, amount));
 }
示例#24
0
 public static void SetDamageMax(this ItemSpec item, float value)
 {
     item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.DamageMax, value));
 }
示例#25
0
        public static void SetCost(this ItemSpec item, int value)
        {
            var spec = new ItemSpecProperty((short)ItemSpecPropertyEnum.Cost, value);

            item.SetProperty(spec);
        }
示例#26
0
 public static DamageTypeEnum GetDamageType(this ItemSpec item)
 {
     return((DamageTypeEnum)(item.GetProperty(ItemSpecPropertyEnum.DamageType).ShortValue));
 }
示例#27
0
        /**/
        public static byte GetStackMax(this ItemSpec item)
        {
            return(item.GetProperty(ItemSpecPropertyEnum.StackMax).ByteValue);
        }

        public static void SetStackMax(this ItemSpec item, byte value)
        {
            var spec = new ItemSpecProperty((short)ItemSpecPropertyEnum.StackMax, value);

            item.SetProperty(spec);
        }

        /**/
        public static short GetDurabilityMax(this ItemSpec item)
        {
            return(item.GetProperty(ItemSpecPropertyEnum.DurabilityMax).ShortValue);
        }
示例#28
0
 public static void SetDamageType(this ItemSpec item, DamageTypeEnum type)
 {
     item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.DamageType, (short)type));
 }
示例#29
0
 public static bool HasDurability(this ItemSpec item)
 {
     return(item.GetProperty(ItemSpecPropertyEnum.DurabilityMax) != null);
 }
示例#30
0
 public static bool IsBodywear(this ItemSpec item)
 {
     return(item.CanBeWornOnLocation(ArmourWearLocation.Body));
 }