public Shield(BaseShield Item, uint ContainerID) { Item.UpdateLocalizedProperties(); Item.UpdateTextProperties(); //General ID = Item.Serial.Value; this.ContainerID = ContainerID; ItemName = Item.Tooltip.Split('|')[0]; SC = Item.Attributes.SpellChanneling; DI = (sbyte)Item.Attributes.WeaponDamage; SSI = (sbyte)Item.Attributes.WeaponSpeed; FC = (sbyte)Item.Attributes.CastSpeed; RPD = (sbyte)Item.Attributes.ReflectPhysical; DCI = (sbyte)Item.Attributes.DefendChance; HCI = (sbyte)Item.Attributes.AttackChance; STR = (sbyte)Item.Attributes.BonusStr; DEX = (sbyte)Item.Attributes.BonusDex; INTEL = (sbyte)Item.Attributes.BonusInt; HP = (sbyte)Item.Attributes.BonusHits; Stam = (sbyte)Item.Attributes.BonusStam; Mana = (sbyte)Item.Attributes.BonusMana; HPRegen = (sbyte)Item.Attributes.RegenHits; StamRegen = (sbyte)Item.Attributes.RegenStam; ManaRegen = (sbyte)Item.Attributes.RegenMana; LMC = (sbyte)Item.Attributes.LowerManaCost; LRC = (sbyte)Item.Attributes.LowerRegCost; EnhancePotions = (sbyte)Item.Attributes.EnhancePotions; Luck = (short)Item.Attributes.Luck; Brittle = Item.Brittle; Added = DateTime.Now; }
public Shield(BaseShield Item, uint ContainerID) { Item.UpdateLocalizedProperties(); Item.UpdateTextProperties(); //General ID = Item.Serial.Value; this.ContainerID = ContainerID; ItemName = Item.Tooltip.Split('|')[0]; SC = Item.Attributes.SpellChanneling; DI = (sbyte)Item.Attributes.WeaponDamage; SSI = (sbyte)Item.Attributes.WeaponSpeed; FC = (sbyte)Item.Attributes.CastSpeed; RPD = (sbyte)Item.Attributes.ReflectPhysical; DCI = (sbyte)Item.Attributes.DefendChance; HCI = (sbyte)Item.Attributes.AttackChance; STR = (sbyte)Item.Attributes.BonusStr; DEX = (sbyte)Item.Attributes.BonusDex; INTEL = (sbyte)Item.Attributes.BonusInt; HP = (sbyte)Item.Attributes.BonusHits; Stam = (sbyte)Item.Attributes.BonusStam; Mana = (sbyte)Item.Attributes.BonusMana; HPRegen = (sbyte)Item.Attributes.RegenHits; StamRegen = (sbyte)Item.Attributes.RegenStam; ManaRegen = (sbyte)Item.Attributes.RegenMana; LMC = (sbyte)Item.Attributes.LowerManaCost; LRC = (sbyte)Item.Attributes.LowerRegCost; EnhancePotions = (sbyte)Item.Attributes.EnhancePotions; Luck = (short)Item.Attributes.Luck; Brittle = Item.Brittle; Added = DateTime.Now; //item rating if (RPD > 0) { Rating += (RPD / 5); } if (DI >= 0) { Rating += (DI / 5) + (DI / 10); } if (HCI > 0) { Rating += (HCI / 2) + (HCI / 3); } if (DCI > 0) { Rating += (DCI / 2) + (DCI / 3); } if (HPRegen > 0) { Rating += (HPRegen * 4); } if (ManaRegen > 0) { Rating += (ManaRegen * 4); } if (StamRegen > 0) { Rating += (StamRegen * 3); } if (LRC > 0) { Rating += (LRC / 2) + (LRC / 3); } if (LMC > 0) { Rating += (LMC / 2) + (LMC / 3); } if (INTEL > 0) { Rating += (INTEL / 2) + (INTEL / 3); } if (DEX > 0) { Rating += (DEX / 2) + (DEX / 3); } if (STR > 0) { Rating += (STR / 2) + (STR / 3); } if (HP > 0) { Rating += (HP / 2) + (HP / 3); } if (Stam > 0) { Rating += (Stam / 2) + (Stam / 3); } if (Mana > 0) { Rating += (Mana / 2) + (Mana / 3); } if (FC > 0) { Rating += (FC * 6); } if (SSI > 0) { Rating += (SSI / 3) + (SSI / 10); } if (Luck > 0) { Rating += (Luck / 11) + (Luck / 15); } if (EnhancePotions > 0) { Rating += (EnhancePotions / 6); } }