* Make cache, actually cache.

arthursv
Adam Frisby 2009-08-21 14:20:05 +10:00
parent 29e2067ec3
commit 98da8e9b16
1 changed files with 5 additions and 1 deletions

View File

@ -48,7 +48,11 @@ namespace OpenSim.Region.OptionalModules.World.NPC
if (m_appearanceCache.ContainsKey(target)) if (m_appearanceCache.ContainsKey(target))
return m_appearanceCache[target]; return m_appearanceCache[target];
return scene.CommsManager.AvatarService.GetUserAppearance(target); AvatarAppearance x = scene.CommsManager.AvatarService.GetUserAppearance(target);
m_appearanceCache.Add(target, x);
return x;
} }
public UUID CreateNPC(string firstname, string lastname,Vector3 position, Scene scene, UUID cloneAppearanceFrom) public UUID CreateNPC(string firstname, string lastname,Vector3 position, Scene scene, UUID cloneAppearanceFrom)