mirror of
https://github.com/opensim/opensim.git
synced 2026-08-12 04:05:42 +08:00
* Converts ClientManager.ForEach() (and as a result, Scene.ForEachClient()) to use a non-blocking parallel method when operating in async mode
* Minor code readability cleanup
This commit is contained in:
@@ -394,7 +394,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
void ProcessViewerEffect(IClientAPI remoteClient, List<ViewerEffectEventHandlerArg> args)
|
||||
{
|
||||
// TODO: don't create new blocks if recycling an old packet
|
||||
List<ViewerEffectPacket.EffectBlock> effectBlock = new List<ViewerEffectPacket.EffectBlock>();
|
||||
ViewerEffectPacket.EffectBlock[] effectBlockArray = new ViewerEffectPacket.EffectBlock[args.Count];
|
||||
for (int i = 0; i < args.Count; i++)
|
||||
{
|
||||
ViewerEffectPacket.EffectBlock effect = new ViewerEffectPacket.EffectBlock();
|
||||
@@ -404,9 +404,8 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
effect.ID = args[i].ID;
|
||||
effect.Type = args[i].Type;
|
||||
effect.TypeData = args[i].TypeData;
|
||||
effectBlock.Add(effect);
|
||||
effectBlockArray[i] = effect;
|
||||
}
|
||||
ViewerEffectPacket.EffectBlock[] effectBlockArray = effectBlock.ToArray();
|
||||
|
||||
ForEachClient(
|
||||
delegate(IClientAPI client)
|
||||
|
||||
Reference in New Issue
Block a user