Fixes casting checks
This commit is contained in:
parent
7ea00fbf4f
commit
03dd5f1926
431 changed files with 5616 additions and 6250 deletions
|
|
@ -38,7 +38,7 @@ namespace Server.Items
|
|||
|
||||
int version = reader.ReadInt();
|
||||
|
||||
if( version == 0 && Core.ML )
|
||||
if ( version == 0 && Core.ML )
|
||||
Layer = Layer.OneHanded;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ namespace Server.Items
|
|||
|
||||
int version = reader.ReadInt();
|
||||
|
||||
if( version == 0 && Core.ML )
|
||||
if ( version == 0 && Core.ML )
|
||||
Layer = Layer.OneHanded;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ namespace Server.Items
|
|||
|
||||
int version = reader.ReadInt();
|
||||
|
||||
if( version == 0 && Core.ML )
|
||||
if ( version == 0 && Core.ML )
|
||||
Layer = Layer.OneHanded;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -91,16 +91,16 @@ namespace Server.Items
|
|||
}
|
||||
|
||||
public override int LabelNumber
|
||||
{
|
||||
{
|
||||
get
|
||||
{
|
||||
if( m_Held > 0 && ( int )m_Type >= ( int )PotionEffect.Conflagration )
|
||||
if ( m_Held > 0 && ( int )m_Type >= ( int )PotionEffect.Conflagration )
|
||||
{
|
||||
return 1072658 + ( int )m_Type - ( int )PotionEffect.Conflagration;
|
||||
}
|
||||
|
||||
return (m_Held > 0 ? 1041620 + (int)m_Type : 1041641);
|
||||
}
|
||||
return (m_Held > 0 ? 1041620 + (int)m_Type : 1041641);
|
||||
}
|
||||
}
|
||||
|
||||
public override void GetProperties( ObjectPropertyList list )
|
||||
|
|
@ -248,7 +248,7 @@ namespace Server.Items
|
|||
|
||||
item.Consume( toHold );
|
||||
|
||||
if( !item.Deleted )
|
||||
if ( !item.Deleted )
|
||||
item.Bounce( from );
|
||||
|
||||
return true;
|
||||
|
|
@ -276,7 +276,7 @@ namespace Server.Items
|
|||
|
||||
item.Consume( toHold );
|
||||
|
||||
if( !item.Deleted )
|
||||
if ( !item.Deleted )
|
||||
item.Bounce( from );
|
||||
|
||||
return true;
|
||||
|
|
@ -342,7 +342,7 @@ namespace Server.Items
|
|||
case PotionEffect.ExplosionLesser: return new LesserExplosionPotion();
|
||||
case PotionEffect.Explosion: return new ExplosionPotion();
|
||||
case PotionEffect.ExplosionGreater: return new GreaterExplosionPotion();
|
||||
|
||||
|
||||
case PotionEffect.Conflagration: return new ConflagrationPotion();
|
||||
case PotionEffect.ConflagrationGreater: return new GreaterConflagrationPotion();
|
||||
|
||||
|
|
@ -356,4 +356,4 @@ namespace Server.Items
|
|||
TileData.ItemTable[0x1940].Height = 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -203,7 +203,7 @@ namespace Server.Items
|
|||
m_TargetMap = m.Map;
|
||||
}
|
||||
|
||||
if( !setDesc )
|
||||
if ( !setDesc )
|
||||
m_Description = BaseRegion.GetRuneNameFor( Region.Find( m_Target, m_TargetMap ) );
|
||||
|
||||
CalculateHue();
|
||||
|
|
@ -318,4 +318,4 @@ namespace Server.Items
|
|||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ namespace Server.Items
|
|||
|
||||
int version = reader.ReadInt();
|
||||
|
||||
if( version == 0 && Core.ML )
|
||||
if ( version == 0 && Core.ML )
|
||||
Layer = Layer.OneHanded;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -161,7 +161,7 @@ namespace Server.Items
|
|||
}
|
||||
}
|
||||
|
||||
if( version == 0 )
|
||||
if ( version == 0 )
|
||||
Stackable = Core.ML;
|
||||
}
|
||||
|
||||
|
|
@ -223,7 +223,7 @@ namespace Server.Items
|
|||
|
||||
public override bool StackWith( Mobile from, Item dropped, bool playSound )
|
||||
{
|
||||
if( dropped is BasePotion && ((BasePotion)dropped).m_PotionEffect == m_PotionEffect )
|
||||
if ( dropped is BasePotion && ((BasePotion)dropped).m_PotionEffect == m_PotionEffect )
|
||||
return base.StackWith( from, dropped, playSound );
|
||||
|
||||
return false;
|
||||
|
|
|
|||
|
|
@ -242,7 +242,7 @@ namespace Server.Items
|
|||
m_MinDamage = min;
|
||||
m_MaxDamage = max;
|
||||
|
||||
if( m_From == null )
|
||||
if ( m_From == null )
|
||||
return;
|
||||
|
||||
int alchemySkill = m_From.Skills.Alchemy.Fixed;
|
||||
|
|
|
|||
|
|
@ -94,7 +94,7 @@ namespace Server.Items
|
|||
{
|
||||
from.SendLocalizedMessage( 500236 ); // You should throw it now!
|
||||
|
||||
if( Core.ML )
|
||||
if ( Core.ML )
|
||||
m_Timer = Timer.DelayCall( TimeSpan.FromSeconds( 1.0 ), TimeSpan.FromSeconds( 1.25 ), 5, new TimerStateCallback( Detonate_OnTick ), new object[]{ from, 3 } ); // 3.6 seconds explosion delay
|
||||
else
|
||||
m_Timer = Timer.DelayCall( TimeSpan.FromSeconds( 0.75 ), TimeSpan.FromSeconds( 1.0 ), 4, new TimerStateCallback( Detonate_OnTick ), new object[]{ from, 3 } ); // 2.6 seconds explosion delay
|
||||
|
|
@ -205,9 +205,9 @@ namespace Server.Items
|
|||
|
||||
to = new Entity( Serial.Zero, new Point3D( p ), map );
|
||||
|
||||
if( p is Mobile )
|
||||
if ( p is Mobile )
|
||||
{
|
||||
if( !RelativeLocation ) // explosion location = current mob location.
|
||||
if ( !RelativeLocation ) // explosion location = current mob location.
|
||||
p = ((Mobile)p).Location;
|
||||
else
|
||||
to = (Mobile)p;
|
||||
|
|
@ -215,7 +215,7 @@ namespace Server.Items
|
|||
|
||||
Effects.SendMovingEffect( from, to, m_Potion.ItemID, 7, 0, false, false, m_Potion.Hue, 0 );
|
||||
|
||||
if( m_Potion.Amount > 1 )
|
||||
if ( m_Potion.Amount > 1 )
|
||||
{
|
||||
Mobile.LiftItemDupe( m_Potion, 1 );
|
||||
}
|
||||
|
|
|
|||
|
|
@ -203,7 +203,7 @@ namespace Server.Items
|
|||
|
||||
LootType = LootType.Blessed;
|
||||
|
||||
if( Core.SE && Weight == 3.0 )
|
||||
if ( Core.SE && Weight == 3.0 )
|
||||
Weight = 1.0;
|
||||
|
||||
int version = reader.ReadInt();
|
||||
|
|
|
|||
|
|
@ -158,9 +158,9 @@ namespace Server.Items
|
|||
return SpellbookType.Necromancer;
|
||||
else if ( spellID >= 200 && spellID < 210 )
|
||||
return SpellbookType.Paladin;
|
||||
else if( spellID >= 400 && spellID < 406 )
|
||||
else if ( spellID >= 400 && spellID < 406 )
|
||||
return SpellbookType.Samurai;
|
||||
else if( spellID >= 500 && spellID < 508 )
|
||||
else if ( spellID >= 500 && spellID < 508 )
|
||||
return SpellbookType.Ninja;
|
||||
else if ( spellID >= 600 && spellID < 617 )
|
||||
return SpellbookType.Arcanist;
|
||||
|
|
@ -597,17 +597,17 @@ namespace Server.Items
|
|||
|
||||
m_AosSkillBonuses.GetProperties( list );
|
||||
|
||||
if( m_Slayer != SlayerName.None )
|
||||
if ( m_Slayer != SlayerName.None )
|
||||
{
|
||||
SlayerEntry entry = SlayerGroup.GetEntryByName( m_Slayer );
|
||||
if( entry != null )
|
||||
if ( entry != null )
|
||||
list.Add( entry.Title );
|
||||
}
|
||||
|
||||
if( m_Slayer2 != SlayerName.None )
|
||||
if ( m_Slayer2 != SlayerName.None )
|
||||
{
|
||||
SlayerEntry entry = SlayerGroup.GetEntryByName( m_Slayer2 );
|
||||
if( entry != null )
|
||||
if ( entry != null )
|
||||
list.Add( entry.Title );
|
||||
}
|
||||
|
||||
|
|
@ -879,9 +879,9 @@ namespace Server.Items
|
|||
|
||||
if ( magery >= 1000 )
|
||||
{
|
||||
if( magery >= 1200 )
|
||||
if ( magery >= 1200 )
|
||||
propertyCounts = m_LegendPropertyCounts;
|
||||
else if( magery >= 1100 )
|
||||
else if ( magery >= 1100 )
|
||||
propertyCounts = m_ElderPropertyCounts;
|
||||
else
|
||||
propertyCounts = m_GrandPropertyCounts;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue