This commit is contained in:
mark 2009-06-28 03:36:42 +00:00
parent c63a5f13fa
commit 2204d5fb86
86 changed files with 1077 additions and 257 deletions

View file

@ -82,7 +82,7 @@ namespace Server.SkillHandlers
public static void ScaleSkills( BaseCreature bc, double scalar )
{
int totalCapIncrease = 0;
int totalCapIncrease = Core.SE ? 2000 : 0; // 2000 points for GM Anatomy and Meditation
for ( int i = 0; i < bc.Skills.Length; ++i )
{
@ -246,7 +246,7 @@ namespace Server.SkillHandlers
m_Creature.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 502796, m_Tamer.NetState ); // You are dead, and cannot continue taming.
Stop();
}
else if ( !m_Tamer.CanSee( m_Creature ) || !m_Tamer.InLOS( m_Creature ) )
else if ( !m_Tamer.CanSee( m_Creature ) || !m_Tamer.InLOS( m_Creature ) || !CanPath() )
{
m_BeingTamed.Remove( m_Creature );
m_Tamer.NextSkillTime = DateTime.Now;
@ -356,6 +356,21 @@ namespace Server.SkillHandlers
}
}
}
private bool CanPath()
{
IPoint3D p = m_Tamer as IPoint3D;
if ( p == null )
return false;
if( m_Creature.InRange( new Point3D( p ), 1 ) )
return true;
MovementPath path = new MovementPath( m_Creature, new Point3D( p ) );
return path.Success;
}
}
}
}

View file

@ -23,12 +23,17 @@ namespace Server.SkillHandlers
public static TimeSpan OnUse( Mobile m )
{
if ( m.Target != null || m.Spell != null )
if ( m.Spell != null )
{
m.SendLocalizedMessage( 501238 ); // You are busy doing something else and cannot hide.
return TimeSpan.FromSeconds( 1.0 );
}
if ( Core.ML && m.Target != null )
{
Targeting.Target.Cancel( m );
}
double bonus = 0.0;
BaseHouse house = BaseHouse.FindHouseAt( m );

View file

@ -95,7 +95,7 @@ namespace Server.SkillHandlers
foreach ( Mobile m in from.GetMobilesInRange( range ) )
{
if ( (m is BaseCreature && ((BaseCreature)m).Uncalmable) || m == from || !from.CanBeHarmful( m, false ) )
if ((m is BaseCreature && ((BaseCreature)m).Uncalmable) || (m is BaseCreature && ((BaseCreature)m).AreaPeaceImmune) || m == from || !from.CanBeHarmful ( m, false ))
continue;
calmed = true;