/****/ public static void AddArmourType(this ItemSpec item, ArmourWearLocation type) { var prop = item.GetProperty(ItemSpecPropertyEnum.ArmourType); if (prop == null) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.ArmourType, (short)type)); } else { var value = prop.ShortValue | (short)type; item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.ArmourType, value)); } }
public ItemSpec Clone(int id) { var ret = new ItemSpec(id); foreach (var item in _properties) { ret.SetProperty(item.Value); } return(ret); }
public static void SetWeaponNoiseDistance(this ItemSpec item, float value) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.NoiseRange, value)); }
public static void SetModelName(this ItemSpec item, string value) { var spec = new ItemSpecProperty((short)ItemSpecPropertyEnum.ModelName, value); item.SetProperty(spec); }
public static void SetHealAmount(this ItemSpec item, short value) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.HealAmount, value)); }
public static void SetHungerReduceAmount(this ItemSpec item, short value) { var spec = new ItemSpecProperty((short)ItemSpecPropertyEnum.HungerReduceAmount, value); item.SetProperty(spec); }
public static void SetDescription(this ItemSpec item, string value) { var spec = new ItemSpecProperty((short)ItemSpecPropertyEnum.Description, value); item.SetProperty(spec); }
public static void SetDurabilityMax(this ItemSpec item, short value) { var spec = new ItemSpecProperty((short)ItemSpecPropertyEnum.DurabilityMax, value); item.SetProperty(spec); }
public static void SetResourceAmount(this ItemSpec item, byte amount) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.ResourceAmount, amount)); }
public static void SetReloadClipSize(this ItemSpec item, short size) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.ReloadClipSize, size)); }
public static void SetClipSize(this ItemSpec item, short value) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.ClipSize, value)); }
public static void SetMeleeRange(this ItemSpec item, float value) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.MeleeRange, value)); }
public static void SetWeaponDelay(this ItemSpec item, uint value) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.UsageDelay, (int)value)); }
public static void SetWeaponType(this ItemSpec item, WeaponTypes value) { item.SetProperty(new ItemSpecProperty((short)ItemSpecPropertyEnum.WeaponType, (short)value)); }
public static void SetAmmoType(this ItemSpec item, AmmoType value) { item.SetProperty(new ItemSpecProperty((short)ItemSpecPropertyEnum.AmmoType, (short)value)); }
public static void SetDefenceMultipliers(this ItemSpec item, Dictionary <DamageTypeEnum, float> multipliers) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.DefenceValues, multipliers)); }
public static void SetResourceType(this ItemSpec item, ResourceType resource) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.ResouceType, (short)resource)); }
public static void SetBulletSpread(this ItemSpec item, float value) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.BulletSpread, value)); }
public static void SetCost(this ItemSpec item, int value) { var spec = new ItemSpecProperty((short)ItemSpecPropertyEnum.Cost, value); item.SetProperty(spec); }
public static void SetDamageMax(this ItemSpec item, float value) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.DamageMax, value)); }
public static void SetDamageType(this ItemSpec item, DamageTypeEnum type) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.DamageType, (short)type)); }
public static void SetBaseUsageTime(this ItemSpec item, short value) { item.SetProperty(new ItemSpecProperty(ItemSpecPropertyEnum.BaseUsageTime, value)); }