aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase
diff options
context:
space:
mode:
authorMelanie Thielker2008-08-16 02:00:36 +0000
committerMelanie Thielker2008-08-16 02:00:36 +0000
commit328ab79b783d4beaa5f954918e3b306950153c1a (patch)
treee2bf03b6cc7c6514a9c83968a716648394602e14 /OpenSim/Region/ScriptEngine/Common/ScriptEngineBase
parentPerils of copypaste. Missing references. (diff)
downloadopensim-SC_OLD-328ab79b783d4beaa5f954918e3b306950153c1a.zip
opensim-SC_OLD-328ab79b783d4beaa5f954918e3b306950153c1a.tar.gz
opensim-SC_OLD-328ab79b783d4beaa5f954918e3b306950153c1a.tar.bz2
opensim-SC_OLD-328ab79b783d4beaa5f954918e3b306950153c1a.tar.xz
Refactor a lot of direct calls to OGS1 to use the cached version instead.
Scripts can now no longer DOS the user server and there are a lot fewer gratuitious lookups of user profile data.
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Common/ScriptEngineBase')
-rw-r--r--OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/AsyncCommandPlugins/SensorRepeat.cs7
1 files changed, 4 insertions, 3 deletions
diff --git a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/AsyncCommandPlugins/SensorRepeat.cs b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/AsyncCommandPlugins/SensorRepeat.cs
index aaea2ee..9b636fd 100644
--- a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/AsyncCommandPlugins/SensorRepeat.cs
+++ b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/AsyncCommandPlugins/SensorRepeat.cs
@@ -30,6 +30,7 @@ using System.Collections.Generic;
30using libsecondlife; 30using libsecondlife;
31using OpenSim.Framework; 31using OpenSim.Framework;
32using OpenSim.Region.Environment.Scenes; 32using OpenSim.Region.Environment.Scenes;
33using OpenSim.Framework.Communications.Cache;
33 34
34namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase.AsyncCommandPlugins 35namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase.AsyncCommandPlugins
35{ 36{
@@ -272,10 +273,10 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase.AsyncCommandPlugin
272 string entname =ent.Name; 273 string entname =ent.Name;
273 274
274 // try avatar username surname 275 // try avatar username surname
275 UserProfileData profile = m_CmdManager.m_ScriptEngine.World.CommsManager.UserService.GetUserProfile(ent.UUID); 276 CachedUserInfo profile = m_CmdManager.m_ScriptEngine.World.CommsManager.UserProfileCacheService.GetUserDetails(ent.UUID);
276 if (profile != null) 277 if (profile != null && profile.UserProfile != null)
277 { 278 {
278 avatarname = profile.FirstName + " " + profile.SurName; 279 avatarname = profile.UserProfile.FirstName + " " + profile.UserProfile.SurName;
279 } 280 }
280 // try an scene object 281 // try an scene object
281 SceneObjectPart SOP = m_CmdManager.m_ScriptEngine.World.GetSceneObjectPart(ent.UUID); 282 SceneObjectPart SOP = m_CmdManager.m_ScriptEngine.World.GetSceneObjectPart(ent.UUID);