本文整理汇总了C#中AosArmorAttributes类的典型用法代码示例。如果您正苦于以下问题:C# AosArmorAttributes类的具体用法?C# AosArmorAttributes怎么用?C# AosArmorAttributes使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
AosArmorAttributes类属于命名空间,在下文中一共展示了AosArmorAttributes类的19个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: 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 );
}
开发者ID:justdanofficial,项目名称:khaeros,代码行数:10,代码来源:ArmourBackpack.cs
示例2: 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;
}
开发者ID:kamronbatman,项目名称:Defiance-AOS-Pre-2012,代码行数:12,代码来源:BaseOtherEquipable.cs
示例3: 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 );
}
开发者ID:FreeReign,项目名称:Rebirth-Repack,代码行数:15,代码来源:BaseArmor.cs
示例4: 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);
}
开发者ID:FreeReign,项目名称:forkuo,代码行数:16,代码来源:BaseClothing.cs
示例5: 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);
}
开发者ID:FreeReign,项目名称:forkuo,代码行数:18,代码来源:BaseArmor.cs
示例6: 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;
}
开发者ID:kamronbatman,项目名称:Defiance-AOS-Pre-2012,代码行数:20,代码来源:BaseArmor.cs
示例7: ApplyAttribute
private static void ApplyAttribute( AosArmorAttributes attrs, int min, int max, AosArmorAttribute attr, int low, int high, int scale )
{
attrs[attr] = Scale( min, max, low / scale, high / scale ) * scale;
}
开发者ID:ITLongwell,项目名称:aedilis2server,代码行数:4,代码来源:BaseRunicTool.cs
示例8: 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);
this.m_SAAbsorptionAttributes = new SAAbsorptionAttributes(this);
m_NegativeAttributes = new NegativeAttributes(this);
#region Mondain's Legacy Sets
this.m_SetAttributes = new AosAttributes(this);
this.m_SetSkillBonuses = new AosSkillBonuses(this);
#endregion
}
开发者ID:Crome696,项目名称:ServUO,代码行数:23,代码来源:BaseClothing.cs
示例9: Deserialize
public override void Deserialize( GenericReader reader )
{
base.Deserialize( reader );
int version = reader.ReadInt();
switch ( version )
{
case 1:
{
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.ArmorAttributes ) )
m_AosArmorAttributes = new AosArmorAttributes( this, reader );
else
m_AosArmorAttributes = new AosArmorAttributes( this );
if ( GetSaveFlag( flags, SaveFlag.Crafter ) )
m_Crafter = reader.ReadMobile();
if ( GetSaveFlag( flags, SaveFlag.Quality ) )
m_Quality = (CraftQuality)reader.ReadEncodedInt();
else
m_Quality = CraftQuality.Regular;
if ( GetSaveFlag( flags, SaveFlag.Resource ) )
m_Resource = (CraftResource)reader.ReadEncodedInt();
else
m_Resource = DefaultResource;
if ( m_Resource == CraftResource.None )
m_Resource = DefaultResource;
if ( GetSaveFlag( flags, SaveFlag.StrReq ) )
m_StrReq = reader.ReadEncodedInt();
else
m_StrReq = -1;
if ( GetSaveFlag( flags, SaveFlag.DexReq ) )
m_DexReq = reader.ReadEncodedInt();
else
m_DexReq = -1;
if ( GetSaveFlag( flags, SaveFlag.IntReq ) )
m_IntReq = reader.ReadEncodedInt();
else
m_IntReq = -1;
if ( GetSaveFlag( flags, SaveFlag.SkillBonuses ) )
m_AosSkillBonuses = new AosSkillBonuses( this, reader );
if ( GetSaveFlag( flags, SaveFlag.PlayerConstructed ) )
m_PlayerConstructed = true;
if ( GetSaveFlag( flags, SaveFlag.BonusRandomAttributes ) )
{
m_BonusRandomAttributes = new BonusAttribute[reader.ReadInt()];
for( int i = 0; i < m_BonusRandomAttributes.Length; i++ )
m_BonusRandomAttributes[i] = new BonusAttribute( reader );
}
break;
}
case 0:
{
m_InheritsItem = true;
m_OldVersion = version;
m_AosAttributes = new AosAttributes( this );
m_AosArmorAttributes = new AosArmorAttributes( this );
m_Quality = CraftQuality.Regular;
m_Resource = DefaultResource;
m_PlayerConstructed = true;
break;
}
}
if ( m_AosSkillBonuses == null )
m_AosSkillBonuses = new AosSkillBonuses( this );
if ( Core.AOS && Parent is Mobile )
m_AosSkillBonuses.AddTo( (Mobile)Parent );
if ( Parent is Mobile )
((Mobile)Parent).CheckStatTimers();
}
开发者ID:kamronbatman,项目名称:Defiance-AOS-Pre-2012,代码行数:91,代码来源:BaseOtherEquipable.cs
示例10: Deserialize
public override void Deserialize( GenericReader reader )
{
base.Deserialize( reader );
int version = reader.ReadInt();
switch ( version )
{
#region Personal Bless Deed
case 9:
{
m_BlessedBy = reader.ReadMobile();
goto case 8;
}
#endregion
#region Mondain's Legacy Sets
case 8:
SetFlag sflags = (SetFlag) reader.ReadEncodedInt();
if ( GetSaveFlag( sflags, SetFlag.Attributes ) )
m_SetAttributes = new AosAttributes( this, reader );
else
m_SetAttributes = new AosAttributes( this );
if ( GetSaveFlag( sflags, SetFlag.ArmorAttributes ) )
m_SetSelfRepair = (new AosArmorAttributes( this, reader )).SelfRepair;
if ( GetSaveFlag( sflags, SetFlag.SkillBonuses ) )
m_SetSkillBonuses = new AosSkillBonuses( this, reader );
else
m_SetSkillBonuses = new AosSkillBonuses( this );
if ( GetSaveFlag( sflags, SetFlag.PhysicalBonus ) )
m_SetPhysicalBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( sflags, SetFlag.FireBonus ) )
m_SetFireBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( sflags, SetFlag.ColdBonus ) )
m_SetColdBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( sflags, SetFlag.PoisonBonus ) )
m_SetPoisonBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( sflags, SetFlag.EnergyBonus ) )
m_SetEnergyBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( sflags, SetFlag.Hue ) )
m_SetHue = reader.ReadEncodedInt();
if ( GetSaveFlag( sflags, SetFlag.LastEquipped ) )
m_LastEquipped = reader.ReadBool();
if ( GetSaveFlag( sflags, SetFlag.SetEquipped ) )
m_SetEquipped = reader.ReadBool();
if ( GetSaveFlag( sflags, SetFlag.SetSelfRepair ) )
m_SetSelfRepair = reader.ReadEncodedInt();
goto case 7;
#endregion
case 7:
case 6:
case 5:
{
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.ArmorAttributes ) )
m_AosArmorAttributes = new AosArmorAttributes( this, reader );
else
m_AosArmorAttributes = new AosArmorAttributes( this );
if ( GetSaveFlag( flags, SaveFlag.PhysicalBonus ) )
m_PhysicalBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.FireBonus ) )
m_FireBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.ColdBonus ) )
m_ColdBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.PoisonBonus ) )
m_PoisonBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.EnergyBonus ) )
m_EnergyBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.Identified ) )
m_Identified = ( version >= 7 || reader.ReadBool() );
if ( GetSaveFlag( flags, SaveFlag.MaxHitPoints ) )
m_MaxHitPoints = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.HitPoints ) )
m_HitPoints = reader.ReadEncodedInt();
//.........这里部分代码省略.........
开发者ID:suiy187,项目名称:runuocustom,代码行数:101,代码来源:BaseArmor.cs
示例11: Deserialize
public override void Deserialize( GenericReader reader )
{
base.Deserialize( reader );
int version = reader.ReadInt();
switch ( version )
{
case 7:
DonationClothing = reader.ReadBool();
Owner = reader.ReadMobile();
goto case 6;
case 6:
m_IsRenamed = reader.ReadBool();
goto case 5;
case 5:
{
SaveFlag flags = (SaveFlag)reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.Resource ) )
m_Resource = (CraftResource)reader.ReadEncodedInt();
else
m_Resource = DefaultResource;
if ( GetSaveFlag( flags, SaveFlag.Attributes ) )
m_AosAttributes = new AosAttributes( this, reader );
else
m_AosAttributes = new AosAttributes( this );
if ( GetSaveFlag( flags, SaveFlag.ClothingAttributes ) )
m_AosClothingAttributes = new AosArmorAttributes( this, reader );
else
m_AosClothingAttributes = new AosArmorAttributes( this );
if ( GetSaveFlag( flags, SaveFlag.SkillBonuses ) )
m_AosSkillBonuses = new AosSkillBonuses( this, reader );
else
m_AosSkillBonuses = new AosSkillBonuses( this );
if ( GetSaveFlag( flags, SaveFlag.Resistances ) )
m_AosResistances = new AosElementAttributes( this, reader );
else
m_AosResistances = new AosElementAttributes( this );
if ( GetSaveFlag( flags, SaveFlag.MaxHitPoints ) )
m_MaxHitPoints = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.HitPoints ) )
m_HitPoints = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.Crafter ) )
m_Crafter = reader.ReadMobile();
if ( GetSaveFlag( flags, SaveFlag.Quality ) )
m_Quality = (ClothingQuality)reader.ReadEncodedInt();
else
m_Quality = ClothingQuality.Regular;
if ( GetSaveFlag( flags, SaveFlag.StrReq ) )
m_StrReq = reader.ReadEncodedInt();
else
m_StrReq = -1;
if ( GetSaveFlag( flags, SaveFlag.PlayerConstructed ) )
m_PlayerConstructed = true;
break;
}
case 4:
{
m_Resource = (CraftResource)reader.ReadInt();
goto case 3;
}
case 3:
{
m_AosAttributes = new AosAttributes( this, reader );
m_AosClothingAttributes = new AosArmorAttributes( this, reader );
m_AosSkillBonuses = new AosSkillBonuses( this, reader );
m_AosResistances = new AosElementAttributes( this, reader );
goto case 2;
}
case 2:
{
m_PlayerConstructed = reader.ReadBool();
goto case 1;
}
case 1:
{
m_Crafter = reader.ReadMobile();
m_Quality = (ClothingQuality)reader.ReadInt();
break;
}
case 0:
{
m_Crafter = null;
m_Quality = ClothingQuality.Regular;
break;
}
//.........这里部分代码省略.........
开发者ID:FreeReign,项目名称:imaginenation,代码行数:101,代码来源:BaseClothing.cs
示例12: Deserialize
public override void Deserialize( GenericReader reader )
{
base.Deserialize( reader );
int version = reader.ReadInt();
switch ( version )
{
case 8:
case 7:
case 6:
case 5:
{
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.ArmorAttributes ) )
m_AosArmorAttributes = new AosArmorAttributes( this, reader );
else
m_AosArmorAttributes = new AosArmorAttributes( this );
if ( GetSaveFlag( flags, SaveFlag.PhysicalBonus ) )
m_PhysicalBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.FireBonus ) )
m_FireBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.ColdBonus ) )
m_ColdBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.PoisonBonus ) )
m_PoisonBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.EnergyBonus ) )
m_EnergyBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.Identified ) )
m_Identified = ( version >= 7 || reader.ReadBool() );
if ( GetSaveFlag( flags, SaveFlag.MaxHitPoints ) )
m_MaxHitPoints = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.HitPoints ) )
m_HitPoints = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.Crafter ) )
m_Crafter = reader.ReadMobile();
if ( GetSaveFlag( flags, SaveFlag.Quality ) )
m_Quality = (ArmorQuality)reader.ReadEncodedInt();
else
m_Quality = ArmorQuality.Regular;
if ( version == 5 && m_Quality == ArmorQuality.Low )
m_Quality = ArmorQuality.Regular;
if ( GetSaveFlag( flags, SaveFlag.Durability ) )
{
m_Durability = (ArmorDurabilityLevel)reader.ReadEncodedInt();
if ( m_Durability > ArmorDurabilityLevel.Indestructible )
m_Durability = ArmorDurabilityLevel.Durable;
}
if ( GetSaveFlag( flags, SaveFlag.Protection ) )
{
m_Protection = (ArmorProtectionLevel)reader.ReadEncodedInt();
if ( m_Protection > ArmorProtectionLevel.Invulnerability )
m_Protection = ArmorProtectionLevel.Defense;
}
if ( GetSaveFlag( flags, SaveFlag.Resource ) )
m_Resource = (CraftResource)reader.ReadEncodedInt();
else
m_Resource = DefaultResource;
if ( m_Resource == CraftResource.None )
m_Resource = DefaultResource;
if ( GetSaveFlag( flags, SaveFlag.BaseArmor ) )
m_ArmorBase = reader.ReadEncodedInt();
else
m_ArmorBase = -1;
if ( GetSaveFlag( flags, SaveFlag.StrBonus ) )
m_StrBonus = reader.ReadEncodedInt();
else
m_StrBonus = -1;
if ( GetSaveFlag( flags, SaveFlag.DexBonus ) )
m_DexBonus = reader.ReadEncodedInt();
else
m_DexBonus = -1;
if ( GetSaveFlag( flags, SaveFlag.IntBonus ) )
//.........这里部分代码省略.........
开发者ID:greeduomacro,项目名称:vivre-uo,代码行数:101,代码来源:BaseArmor.cs
示例13: 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);
if ((this is WoodenShield || this is LeatherShield || this is BoiledLeatherShield) && this.Resource == CraftResource.Iron)
this.Resource = CraftResource.Oak;
else if (this.Resource == CraftResource.Iron)
{
this.Resource = CraftResource.Copper;
this.Hue = 0x96D;
}
if (this is IBoneArmour)
{
this.Hue = 0;
}
}
开发者ID:justdanofficial,项目名称:khaeros,代码行数:32,代码来源:BaseArmor.cs
示例14: Deserialize
public override void Deserialize(GenericReader reader)
{
base.Deserialize(reader);
int version = reader.ReadInt();
//if (version == 11)
//version = 12;
switch (version)
{
case 12: m_OldArmor = reader.ReadBool(); goto case 11;
case 11:
case 10:
{
m_CraftersOriginalName = reader.ReadString();
goto case 9;
}
case 9:
{
m_Engraved1 = reader.ReadString();
m_Engraved2 = reader.ReadString();
m_Engraved3 = reader.ReadString();
goto case 5;
}
case 8:
case 7:
case 6:
case 5:
{
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.ArmorAttributes))
m_AosArmorAttributes = new AosArmorAttributes(this, reader);
else
m_AosArmorAttributes = new AosArmorAttributes(this);
if (GetSaveFlag(flags, SaveFlag.BluntBonus))
m_BluntBonus = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.SlashingBonus))
m_SlashingBonus = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.PiercingBonus))
m_PiercingBonus = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.PhysicalBonus))
m_PhysicalBonus = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.FireBonus))
m_FireBonus = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.ColdBonus))
m_ColdBonus = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.PoisonBonus))
m_PoisonBonus = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.EnergyBonus))
m_EnergyBonus = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.Identified))
m_Identified = (version >= 7 || reader.ReadBool());
if (GetSaveFlag(flags, SaveFlag.MaxHitPoints))
m_MaxHitPoints = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.HitPoints))
m_HitPoints = reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.Crafter))
m_Crafter = reader.ReadMobile();
if (GetSaveFlag(flags, SaveFlag.Quality))
{
m_Quality = (ArmorQuality)reader.ReadEncodedInt();
}
else
m_Quality = ArmorQuality.Regular;
if (version == 5 && m_Quality == ArmorQuality.Low)
m_Quality = ArmorQuality.Regular;
if (GetSaveFlag(flags, SaveFlag.Durability))
{
m_Durability = (ArmorDurabilityLevel)reader.ReadEncodedInt();
if (m_Durability > ArmorDurabilityLevel.Indestructible)
m_Durability = ArmorDurabilityLevel.Durable;
}
if (GetSaveFlag(flags, SaveFlag.Protection))
{
m_Protection = (ArmorProtectionLevel)reader.ReadEncodedInt();
//.........这里部分代码省略.........
开发者ID:justdanofficial,项目名称:khaeros,代码行数:101,代码来源:BaseArmor.cs
示例15: Deserialize
public override void Deserialize(GenericReader reader)
{
base.Deserialize( reader );
int version = reader.ReadInt();
switch( version )
{
case 12:
case 11:
case 10:
case 9:
case 8:
case 7:
case 6:
case 5:
{
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.ArmorAttributes ) )
m_AosArmorAttributes = new AosArmorAttributes( this, reader );
else
m_AosArmorAttributes = new AosArmorAttributes( this );
if( GetSaveFlag( flags, SaveFlag.BluntBonus ) )
m_BluntBonus = reader.ReadEncodedInt();
if( GetSaveFlag( flags, SaveFlag.SlashingBonus ) )
m_SlashingBonus = reader.ReadEncodedInt();
if( GetSaveFlag( flags, SaveFlag.PiercingBonus ) )
m_PiercingBonus = reader.ReadEncodedInt();
if( GetSaveFlag( flags, SaveFlag.PhysicalBonus ) )
m_PhysicalBonus = reader.ReadEncodedInt();
if( GetSaveFlag( flags, SaveFlag.FireBonus ) )
m_FireBonus = reader.ReadEncodedInt();
if( GetSaveFlag( flags, SaveFlag.ColdBonus ) )
m_ColdBonus = reader.ReadEncodedInt();
if( GetSaveFlag( flags, SaveFlag.PoisonBonus ) )
m_PoisonBonus = reader.ReadEncodedInt();
if( GetSaveFlag( flags, SaveFlag.EnergyBonus ) )
m_EnergyBonus = reader.ReadEncodedInt();
if( GetSaveFlag( flags, SaveFlag.Identified ) )
m_Identified = ( version >= 7 || reader.ReadBool() );
if( GetSaveFlag( flags, SaveFlag.Protection ) )
{
m_Protection = (ArmorProtectionLevel)reader.ReadEncodedInt();
if( m_Protection > ArmorProtectionLevel.Invulnerability )
m_Protection = ArmorProtectionLevel.Defense;
}
if( GetSaveFlag( flags, SaveFlag.BaseArmor ) )
m_ArmorBase = reader.ReadEncodedInt();
else
m_ArmorBase = -1;
if( GetSaveFlag( flags, SaveFlag.HitsMaxBonus ) )
m_HitsMaxBonus = reader.ReadEncodedInt();
else
m_HitsMaxBonus = -1;
if( GetSaveFlag( flags, SaveFlag.StamMaxBonus ) )
m_StamMaxBonus = reader.ReadEncodedInt();
else
m_StamMaxBonus = -1;
if( GetSaveFlag( flags, SaveFlag.ManaMaxBonus ) )
m_ManaMaxBonus = reader.ReadEncodedInt();
else
m_ManaMaxBonus = -1;
if( GetSaveFlag( flags, SaveFlag.StrBonus ) )
m_StrBonus = reader.ReadEncodedInt();
else
m_StrBonus = -1;
if( GetSaveFlag( flags, SaveFlag.DexBonus ) )
m_DexBonus = reader.ReadEncodedInt();
else
m_DexBonus = -1;
if( GetSaveFlag( flags, SaveFlag.IntBonus ) )
m_IntBonus = reader.ReadEncodedInt();
else
m_IntBonus = -1;
if( GetSaveFlag( flags, SaveFlag.StrReq ) )
//.........这里部分代码省略.........
开发者ID:justdanofficial,项目名称:khaeros,代码行数:101,代码来源:ArmourBackpack.cs
示例16: 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);
}
开发者ID:FeehTuffani,项目名称:ServUO,代码行数:38,代码来源:BaseArmor.cs
示例17: Deserialize
public override void Deserialize( GenericReader reader )
{
base.Deserialize( reader );
int version = reader.ReadInt();
switch ( version )
{
case 8:
{
m_Identified = reader.ReadMobileList();
goto case 7;
}
case 7:
case 6:
case 5:
{
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.ArmorAttributes ) )
m_AosArmorAttributes = new AosArmorAttributes( this, reader );
else
m_AosArmorAttributes = new AosArmorAttributes( this );
if ( GetSaveFlag( flags, SaveFlag.PhysicalBonus ) )
m_PhysicalBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.FireBonus ) )
m_FireBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.ColdBonus ) )
m_ColdBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.PoisonBonus ) )
m_PoisonBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.EnergyBonus ) )
m_EnergyBonus = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.Identified ) && version < 7 )
reader.ReadBool();
//m_Identified = ( version >= 7 || reader.ReadBool() );
if ( GetSaveFlag( flags, SaveFlag.MaxHitPoints ) )
m_MaxHitPoints = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.HitPoints ) )
m_HitPoints = reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.Crafter ) )
m_Crafter = reader.ReadMobile();
if ( GetSaveFlag( flags, SaveFlag.Quality ) )
m_Quality = (CraftQuality)reader.ReadEncodedInt();
else
m_Quality = CraftQuality.Regular;
if ( version == 5 && m_Quality == CraftQuality.Low )
m_Quality = CraftQuality.Regular;
if ( GetSaveFlag( flags, SaveFlag.Durability ) )
m_Durability = (DurabilityLevel)reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.Protection ) )
m_Protection = (ArmorProtectionLevel)reader.ReadEncodedInt();
if ( GetSaveFlag( flags, SaveFlag.BaseArmor ) )
m_ArmorBase = reader.ReadEncodedInt();
else
m_ArmorBase = -1;
if ( GetSaveFlag( flags, SaveFlag.StrBonus ) )
m_StrBonus = reader.ReadEncodedInt();
else
m_StrBonus = -1;
if ( GetSaveFlag( flags, SaveFlag.DexBonus ) )
m_DexBonus = reader.ReadEncodedInt();
else
m_DexBonus = -1;
if ( GetSaveFlag( flags, SaveFlag.IntBonus ) )
m_IntBonus = reader.ReadEncodedInt();
else
m_IntBonus = -1;
if ( GetSaveFlag( flags, SaveFlag.StrReq ) )
m_StrReq = reader.ReadEncodedInt();
else
m_StrReq = -1;
if ( GetSaveFlag( flags, SaveFlag.DexReq ) )
m_DexReq = reader.ReadEncodedInt();
else
//.........这里部分代码省略.........
开发者ID:FreeReign,项目名称:Rebirth-Repack,代码行数:101,代码来源:BaseArmor.cs
示例18: 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_SAAbsorptionAttributes = new SAAbsorptionAttributes( this );
#region Mondain's Legacy Sets
m_SetAttributes = new AosAttributes( this );
m_SetSkillBonuses = new AosSkillBonuses( this );
#endregion
}
开发者ID:suiy187,项目名称:runuocustom,代码行数:24,代码来源:BaseArmor.cs
示例19: Deserialize
public override void Deserialize(GenericReader reader)
{
base.Deserialize(reader);
int version = reader.ReadInt();
switch ( version )
{
case 8:
{
this.m_IsImbued = reader.ReadBool();
goto case 7;
}
case 7:
{
m_SAAbsorptionAttributes = new SAAbsorptionAttributes(this, reader);
#region Runic Reforging
m_ReforgedPrefix = (ReforgedPrefix)reader.ReadInt();
m_ReforgedSuffix = (ReforgedSuffix)reader.ReadInt();
m_ItemPower = (ItemPower)reader.ReadInt();
m_BlockRepair = reader.ReadBool();
#endregion
#region Stygian Abyss
m_GorgonLenseCharges = reader.ReadInt();
m_GorgonLenseType = (LenseType)reader.ReadInt();
m_PhysImbuing = reader.ReadInt();
m_FireImbuing = reader.ReadInt();
m_ColdImbuing = reader.ReadInt();
m_PoisonImbuing = reader.ReadInt();
m_EnergyImbuing = reader.ReadInt();
goto case 6;
}
case 6:
{
if(version == 6)
m_SAAbsorptionAttributes = new SAAbsorptionAttributes(this);
this.m_TimesImbued = reader.ReadInt();
#endregion
this.m_BlessedBy = reader.ReadMobile();
#region Mondain's Legacy Sets
SetFlag sflags = (SetFlag)reader.ReadEncodedInt();
if (GetSaveFlag(sflags, SetFlag.Attributes))
this.m_SetAttributes = new AosAttributes(this, reader);
else
this.m_SetAttributes = new AosAttributes(this);
if (GetSaveFlag(sflags, SetFlag.ArmorAttributes))
this.m_SetSelfRepair = (new AosArmorAttributes(this, reader)).SelfRepair;
if (GetSaveFlag(sflags, SetFlag.SkillBonuses))
this.m_SetSkillBonuses = new AosSkillBonuses(this, reader);
else
this.m_SetSkillBonuses = new AosSkillBonuses(this);
if (GetSaveFlag(sflags, SetFlag.PhysicalBonus))
this.m_SetPhysicalBonus = reader.ReadEncodedInt();
if (GetSaveFlag(sflags, SetFlag.FireBonus))
this.m_SetFireBonus = reader.ReadEncodedInt();
if (GetSaveFlag(sflags, SetFlag.ColdBonus))
this.m_SetColdBonus = reader.ReadEncodedInt();
if (GetSaveFlag(sflags, SetFlag.PoisonBonus))
this.m_SetPoisonBonus = reader.ReadEncodedInt();
if (GetSaveFlag(sflags, SetFlag.EnergyBonus))
this.m_SetEnergyBonus = reader.ReadEncodedInt();
if (GetSaveFlag(sflags, SetFlag.SetHue))
this.m_SetHue = reader.ReadEncodedInt();
if (GetSaveFlag(sflags, SetFlag.LastEquipped))
this.m_LastEquipped = reader.ReadBool();
if (GetSaveFlag(sflags, SetFlag.SetEquipped))
this.m_SetEquipped = reader.ReadBool();
if (GetSaveFlag(sflags, SetFlag.SetSelfRepair))
this.m_SetSelfRepair = reader.ReadEncodedInt();
#endregion
goto case 5;
}
case 5:
{
SaveFlag flags = (SaveFlag)reader.ReadEncodedInt();
if (GetSaveFlag(flags, SaveFlag.NegativeAttributes))
m_NegativeAttributes = new NegativeAttributes(this, reader);
else
|
请发表评论