This commit is contained in:
parent
9acbdb6e36
commit
b13cb1ce31
1 changed files with 4 additions and 10 deletions
|
|
@ -4977,21 +4977,15 @@ namespace Server.Mobiles
|
||||||
if ( CanBreath && DateTime.Now >= m_NextBreathTime ) // tested: controlled dragons do breath fire, what about summoned skeletal dragons?
|
if ( CanBreath && DateTime.Now >= m_NextBreathTime ) // tested: controlled dragons do breath fire, what about summoned skeletal dragons?
|
||||||
{
|
{
|
||||||
Mobile target = this.Combatant;
|
Mobile target = this.Combatant;
|
||||||
|
|
||||||
if( target != null && target.Alive && !target.IsDeadBondedPet && CanBeHarmful( target ) && target.Map == this.Map && !IsDeadBondedPet && target.InRange( this, BreathRange ) && InLOS( target ) && !BardPacified )
|
if( target != null && target.Alive && !target.IsDeadBondedPet && CanBeHarmful( target ) && target.Map == this.Map && !IsDeadBondedPet && target.InRange( this, BreathRange ) && InLOS( target ) && !BardPacified )
|
||||||
{
|
{
|
||||||
if( m_NextBreathTime == DateTime.MinValue )
|
if( ( DateTime.Now - m_NextBreathTime ) < TimeSpan.FromSeconds( 30 ) )
|
||||||
{
|
|
||||||
m_NextBreathTime = DateTime.Now + TimeSpan.FromSeconds( BreathMinDelay + ( Utility.RandomDouble() * BreathMaxDelay ) );
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
{
|
||||||
BreathStart( target );
|
BreathStart( target );
|
||||||
}
|
}
|
||||||
}
|
|
||||||
else
|
m_NextBreathTime = DateTime.Now + TimeSpan.FromSeconds( BreathMinDelay + ( Utility.RandomDouble() * BreathMaxDelay ) );
|
||||||
{
|
|
||||||
m_NextBreathTime = DateTime.MinValue;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue