diff options
author | Melanie | 2011-12-09 16:36:25 +0100 |
---|---|---|
committer | Melanie | 2011-12-09 16:36:25 +0100 |
commit | 07c26111afa99280e18274817de8cd752474cad7 (patch) | |
tree | 179ce0745e3ca7e40fd01b34273e3cc0cb95dd32 | |
parent | Reverse the last one (diff) | |
download | opensim-SC_OLD-07c26111afa99280e18274817de8cd752474cad7.zip opensim-SC_OLD-07c26111afa99280e18274817de8cd752474cad7.tar.gz opensim-SC_OLD-07c26111afa99280e18274817de8cd752474cad7.tar.bz2 opensim-SC_OLD-07c26111afa99280e18274817de8cd752474cad7.tar.xz |
Fix llGetLinkKey to report avatars properly
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index 7a56f11..fcb1278 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | |||
@@ -4117,25 +4117,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
4117 | public LSL_String llGetLinkKey(int linknum) | 4117 | public LSL_String llGetLinkKey(int linknum) |
4118 | { | 4118 | { |
4119 | m_host.AddScriptLPS(1); | 4119 | m_host.AddScriptLPS(1); |
4120 | List<UUID> keytable = new List<UUID>(); | ||
4121 | // parse for sitting avatare-uuids | ||
4122 | World.ForEachRootScenePresence(delegate(ScenePresence presence) | ||
4123 | { | ||
4124 | if (presence.ParentID != 0 && m_host.ParentGroup.HasChildPrim(presence.ParentID)) | ||
4125 | keytable.Add(presence.UUID); | ||
4126 | }); | ||
4127 | |||
4128 | int totalprims = m_host.ParentGroup.PrimCount + keytable.Count; | ||
4129 | if (linknum > m_host.ParentGroup.PrimCount && linknum <= totalprims) | ||
4130 | { | ||
4131 | return keytable[totalprims - linknum].ToString(); | ||
4132 | } | ||
4133 | |||
4134 | if (linknum == 1 && m_host.ParentGroup.PrimCount == 1 && keytable.Count == 1) | ||
4135 | { | ||
4136 | return m_host.UUID.ToString(); | ||
4137 | } | ||
4138 | |||
4139 | SceneObjectPart part = m_host.ParentGroup.GetLinkNumPart(linknum); | 4120 | SceneObjectPart part = m_host.ParentGroup.GetLinkNumPart(linknum); |
4140 | if (part != null) | 4121 | if (part != null) |
4141 | { | 4122 | { |