本文整理汇总了C#中AosAttributes类的典型用法代码示例。如果您正苦于以下问题:C# AosAttributes类的具体用法?C# AosAttributes怎么用?C# AosAttributes使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
AosAttributes类属于命名空间,在下文中一共展示了AosAttributes类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: BaseQuiver
public BaseQuiver( int itemID )
: base(itemID)
{
Weight = 2.0;
Capacity = 500;
Layer = Layer.Cloak;
m_Attributes = new AosAttributes( this );
}
示例2: ApplyAttribute
private static void ApplyAttribute( AosAttributes attrs, int min, int max, AosAttribute attr, int low, int high, int scale )
{
if ( attr == AosAttribute.CastSpeed )
attrs[attr] += Scale( min, max, low / scale, high / scale ) * scale;
else
attrs[attr] = Scale( min, max, low / scale, high / scale ) * scale;
if ( attr == AosAttribute.SpellChanneling )
attrs[AosAttribute.CastSpeed] -= 1;
}
示例3: ArmourBackpack
public ArmourBackpack()
: base(0xE75)
{
Layer = Layer.Backpack;
Weight = 3.0;
m_AosAttributes = new AosAttributes( this );
m_AosArmorAttributes = new AosArmorAttributes( this );
m_AosSkillBonuses = new AosSkillBonuses( this );
}
示例4: BaseQuiver
public BaseQuiver(int itemID)
: base(itemID)
{
this.Weight = 2.0;
this.Capacity = 500;
this.Layer = Layer.Cloak;
this.m_Attributes = new AosAttributes(this);
this.DamageIncrease = 10;
}
示例5: BaseJewel
public BaseJewel( int itemID, Layer layer )
: base(itemID)
{
m_AosAttributes = new AosAttributes( this );
m_AosResistances = new AosElementAttributes( this );
m_AosSkillBonuses = new AosSkillBonuses( this );
m_Resource = CraftResource.Iron;
m_GemType = GemType.None;
Layer = layer;
}
示例6: BaseOtherEquipable
public BaseOtherEquipable( int itemID )
: base(itemID)
{
m_Quality = CraftQuality.Regular;
Resource = DefaultResource;
m_AosAttributes = new AosAttributes( this );
m_AosArmorAttributes = new AosArmorAttributes( this );
m_AosSkillBonuses = new AosSkillBonuses( this );
m_OriginalWeight = Weight;
}
示例7: BaseJewel
public BaseJewel( int itemID, Layer layer )
: base(itemID)
{
m_AosAttributes = new AosAttributes( this );
m_AosResistances = new AosElementAttributes( this );
m_AosSkillBonuses = new AosSkillBonuses( this );
m_Resource = CraftResource.Iron;
m_GemType = GemType.None;
Layer = layer;
m_HitPoints = m_MaxHitPoints = Utility.RandomMinMax( InitMinHits, InitMaxHits );
}
示例8: BaseArmor
public BaseArmor( int itemID )
: base(itemID)
{
m_Quality = CraftQuality.Regular;
m_Durability = DurabilityLevel.Regular;
m_Crafter = null;
m_HitPoints = m_MaxHitPoints = Utility.RandomMinMax( InitMinHits, InitMaxHits );
this.Layer = (Layer)ItemData.Quality;
m_AosAttributes = new AosAttributes( this );
m_AosArmorAttributes = new AosArmorAttributes( this );
m_AosSkillBonuses = new AosSkillBonuses( this );
}
示例9: BaseJewel
public BaseJewel(int itemID, Layer layer, JewelEffect effect, int minCharges, int maxCharges)
: base(itemID)
{
m_AosAttributes = new AosAttributes( this );
m_AosResistances = new AosElementAttributes( this );
m_AosSkillBonuses = new AosSkillBonuses( this );
m_Resource = CraftResource.Iron;
m_GemType = GemType.None;
m_IDList = new List<Mobile>();
Layer = layer;
Weight = 1.0;
Effect = effect;
Charges = Utility.RandomMinMax( minCharges, maxCharges );
m_Identified = false;
}
示例10: BaseClothing
public BaseClothing(int itemID, Layer layer, int hue)
: base(itemID)
{
this.Layer = layer;
this.Hue = hue;
this.m_Resource = this.DefaultResource;
this.m_Quality = ClothingQuality.Regular;
this.m_HitPoints = this.m_MaxHitPoints = Utility.RandomMinMax(this.InitMinHits, this.InitMaxHits);
this.m_AosAttributes = new AosAttributes(this);
this.m_AosClothingAttributes = new AosArmorAttributes(this);
this.m_AosSkillBonuses = new AosSkillBonuses(this);
this.m_AosResistances = new AosElementAttributes(this);
}
示例11: BaseArmor
public BaseArmor(int itemID)
: base(itemID)
{
this.m_Quality = ArmorQuality.Regular;
this.m_Durability = ArmorDurabilityLevel.Regular;
this.m_Crafter = null;
this.m_Resource = this.DefaultResource;
this.Hue = CraftResources.GetHue(this.m_Resource);
this.m_HitPoints = this.m_MaxHitPoints = Utility.RandomMinMax(this.InitMinHits, this.InitMaxHits);
this.Layer = (Layer)this.ItemData.Quality;
this.m_AosAttributes = new AosAttributes(this);
this.m_AosArmorAttributes = new AosArmorAttributes(this);
this.m_AosSkillBonuses = new AosSkillBonuses(this);
}
示例12: BaseArmor
public BaseArmor( int itemID )
: base(itemID)
{
m_Quality = ArmorQuality.Regular;
m_Durability = ArmorDurabilityLevel.Regular;
m_Crafter = null;
m_Resource = DefaultResource;
Hue = CraftResources.GetHue( m_Resource );
m_HitPoints = m_MaxHitPoints = Utility.RandomMinMax( InitMinHits, InitMaxHits );
this.Layer = (Layer)ItemData.Quality;
m_AosAttributes = new AosAttributes( this );
m_AosArmorAttributes = new AosArmorAttributes( this );
m_AosSkillBonuses = new AosSkillBonuses( this );
m_OriginalWeight = Weight;
}
示例13: Deserialize
public override void Deserialize(GenericReader reader)
{
base.Deserialize(reader);
int version = reader.ReadInt();
switch (version)
{
case 0:
{
SaveFlag flags = (SaveFlag)reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.Attributes))
m_AosAttributes = new AosAttributes(this, reader);
else
m_AosAttributes = new AosAttributes(this);
if (GetSaveFlag(flags, SaveFlag.SkillBonuses))
m_AosSkillBonuses = new AosSkillBonuses(this, reader);
else
m_AosSkillBonuses = new AosSkillBonuses(this);
// Backward compatibility
if (GetSaveFlag(flags, SaveFlag.Owner))
BlessedFor = reader.ReadMobile();
if (GetSaveFlag(flags, SaveFlag.Protection))
m_Protection = new TalismanAttribute(reader);
else
m_Protection = new TalismanAttribute();
if (GetSaveFlag(flags, SaveFlag.Killer))
m_Killer = new TalismanAttribute(reader);
else
m_Killer = new TalismanAttribute();
if (GetSaveFlag(flags, SaveFlag.Summoner))
m_Summoner = new TalismanAttribute(reader);
else
m_Summoner = new TalismanAttribute();
if (GetSaveFlag(flags, SaveFlag.Removal))
m_Removal = (TalismanRemoval)reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.OldKarmaLoss))
m_AosAttributes.IncreasedKarmaLoss = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.Skill))
m_Skill = (SkillName)reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.SuccessBonus))
m_SuccessBonus = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.ExceptionalBonus))
m_ExceptionalBonus = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.MaxCharges))
m_MaxCharges = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.Charges))
m_Charges = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.MaxChargeTime))
m_MaxChargeTime = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.ChargeTime))
m_ChargeTime = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.Slayer))
m_Slayer = (TalismanSlayerName)reader.ReadEncodedInt();
m_Blessed = GetSaveFlag(flags, SaveFlag.Blessed);
break;
}
}
if (Parent is Mobile)
{
Mobile m = (Mobile)Parent;
m_AosAttributes.AddStatBonuses(m);
m_AosSkillBonuses.AddTo(m);
if (m_ChargeTime > 0)
StartTimer();
}
}
示例14: BaseTalisman
public BaseTalisman(int itemID)
: base(itemID)
{
Layer = Layer.Talisman;
Weight = 1.0;
m_Protection = new TalismanAttribute();
m_Killer = new TalismanAttribute();
m_Summoner = new TalismanAttribute();
m_AosAttributes = new AosAttributes(this);
m_AosSkillBonuses = new AosSkillBonuses(this);
}
示例15: BaseArmor
public BaseArmor(int itemID)
: base(itemID)
{
this.m_Quality = ArmorQuality.Regular;
this.m_Durability = ArmorDurabilityLevel.Regular;
this.m_Crafter = null;
this.m_Resource = this.DefaultResource;
this.Hue = CraftResources.GetHue(this.m_Resource);
this.m_HitPoints = this.m_MaxHitPoints = Utility.RandomMinMax(this.InitMinHits, this.InitMaxHits);
this.Layer = (Layer)this.ItemData.Quality;
this.m_AosAttributes = new AosAttributes(this);
this.m_AosArmorAttributes = new AosArmorAttributes(this);
this.m_AosSkillBonuses = new AosSkillBonuses(this);
this.m_SAAbsorptionAttributes = new SAAbsorptionAttributes(this);
#region Mondain's Legacy Sets
this.m_SetAttributes = new AosAttributes(this);
this.m_SetSkillBonuses = new AosSkillBonuses(this);
#endregion
this.m_AosSkillBonuses = new AosSkillBonuses(this);
// Mod to randomly add sockets and socketability features to armor. These settings will yield
// 2% drop rate of socketed/socketable items
// 0.1% chance of 5 sockets
// 0.5% of 4 sockets
// 3% chance of 3 sockets
// 15% chance of 2 sockets
// 50% chance of 1 socket
// the remainder will be 0 socket (31.4% in this case)
// uncomment the next line to prevent artifacts from being socketed
// if(ArtifactRarity == 0)
XmlSockets.ConfigureRandom(this, 2.0, 0.1, 0.5, 3.0, 15.0, 50.0);
}