parallel delta queue processing

thread safe packet construction, compilation, compression, gump compilation, sending, coalescing, and many other fixes
TODO:  delta queue recursion fixups, ipooledenumerable fixups/generics
This commit is contained in:
Mark Sturgill 2013-10-11 00:01:05 -07:00
parent 9404651774
commit ddcc4e7a20
16 changed files with 619 additions and 575 deletions

View file

@ -2632,7 +2632,8 @@ namespace Server.Mobiles
if (srcSkill <= 0)
return;
foreach (Mobile trg in m_Mobile.GetMobilesInRange(m_Mobile.RangePerception))
IPooledEnumerable eable = m_Mobile.GetMobilesInRange(m_Mobile.RangePerception);
foreach (Mobile trg in eable)
{
if (trg != m_Mobile && trg.Player && trg.Alive && trg.Hidden && trg.AccessLevel == AccessLevel.Player && m_Mobile.InLOS(trg))
{
@ -2655,6 +2656,7 @@ namespace Server.Mobiles
}
}
}
eable.Free();
}
public virtual void Deactivate()

View file

@ -5429,7 +5429,8 @@ namespace Server.Mobiles
{
Corpse toRummage = null;
foreach ( Item item in this.GetItemsInRange( 2 ) )
IPooledEnumerable eable = this.GetItemsInRange(2);
foreach ( Item item in eable )
{
if ( item is Corpse && item.Items.Count > 0 )
{
@ -5437,6 +5438,7 @@ namespace Server.Mobiles
break;
}
}
eable.Free();
if ( toRummage == null )
return false;

View file

@ -1210,27 +1210,17 @@ namespace Server.Mobiles
m_IsStealthing = false; // IsStealthing should be moved to Server.Mobiles
}
[CommandProperty( AccessLevel.GameMaster )]
public override bool Hidden
public override void OnHiddenChanged()
{
get
RemoveBuff(BuffIcon.Invisibility); //Always remove, default to the hiding icon EXCEPT in the invis spell where it's explicitly set
if (!Hidden)
{
return base.Hidden;
RemoveBuff(BuffIcon.HidingAndOrStealth);
}
set
else// if( !InvisibilitySpell.HasTimer( this ) )
{
base.Hidden = value;
RemoveBuff( BuffIcon.Invisibility ); //Always remove, default to the hiding icon EXCEPT in the invis spell where it's explicitly set
if( !Hidden )
{
RemoveBuff( BuffIcon.HidingAndOrStealth );
}
else// if( !InvisibilitySpell.HasTimer( this ) )
{
BuffInfo.AddBuff( this, new BuffInfo( BuffIcon.HidingAndOrStealth, 1075655 ) ); //Hidden/Stealthing & You Are Hidden
}
BuffInfo.AddBuff(this, new BuffInfo(BuffIcon.HidingAndOrStealth, 1075655)); //Hidden/Stealthing & You Are Hidden
}
}