aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs9
1 files changed, 4 insertions, 5 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index 61c5add..5c6d382 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -4232,22 +4232,21 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
4232 UUID uuid = (UUID)id; 4232 UUID uuid = (UUID)id;
4233 4233
4234 UserAccount account = World.UserAccountService.GetUserAccount(World.RegionInfo.ScopeID, uuid); 4234 UserAccount account = World.UserAccountService.GetUserAccount(World.RegionInfo.ScopeID, uuid);
4235 if (account == null)
4236 return UUID.Zero.ToString();
4237
4235 4238
4236 PresenceInfo pinfo = null; 4239 PresenceInfo pinfo = null;
4237 PresenceInfo[] pinfos = World.PresenceService.GetAgents(new string[] { uuid.ToString() }); 4240 PresenceInfo[] pinfos = World.PresenceService.GetAgents(new string[] { uuid.ToString() });
4238 if (pinfos != null && pinfos.Length > 0) 4241 if (pinfos != null && pinfos.Length > 0)
4239 pinfo = pinfos[0]; 4242 pinfo = pinfos[0];
4240 4243
4241 if (pinfo == null)
4242 return UUID.Zero.ToString();
4243
4244 string reply = String.Empty; 4244 string reply = String.Empty;
4245 4245
4246 switch (data) 4246 switch (data)
4247 { 4247 {
4248 case 1: // DATA_ONLINE (0|1) 4248 case 1: // DATA_ONLINE (0|1)
4249 // TODO: implement fetching of this information 4249 if (pinfo != null && pinfo.RegionID != UUID.Zero)
4250 if (pinfo != null)
4251 reply = "1"; 4250 reply = "1";
4252 else 4251 else
4253 reply = "0"; 4252 reply = "0";