aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorubit2013-01-09 18:03:04 +0100
committerubit2013-01-09 18:03:04 +0100
commitf392fa96c398ead47b57cefcad436dfb6a8f6482 (patch)
tree07863eaa9cd70b570f4da0828861cfe185d6483f
parentMerge branch 'ubitwork' of ssh://3dhosting.de/var/git/careminster into ubitwork (diff)
parent stop endless loop in lGetLinkPrimitiveParams (diff)
downloadopensim-SC_OLD-f392fa96c398ead47b57cefcad436dfb6a8f6482.zip
opensim-SC_OLD-f392fa96c398ead47b57cefcad436dfb6a8f6482.tar.gz
opensim-SC_OLD-f392fa96c398ead47b57cefcad436dfb6a8f6482.tar.bz2
opensim-SC_OLD-f392fa96c398ead47b57cefcad436dfb6a8f6482.tar.xz
Merge branch 'ubitwork' of ssh://3dhosting.de/var/git/careminster into ubitwork
-rw-r--r--OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs19
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs14
2 files changed, 30 insertions, 3 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs b/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs
index f6146a9..b06788b 100644
--- a/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs
+++ b/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs
@@ -103,6 +103,7 @@ namespace OpenSim.Region.ClientStack.Linden
103 private static readonly string m_getObjectPhysicsDataPath = "0101/"; 103 private static readonly string m_getObjectPhysicsDataPath = "0101/";
104 private static readonly string m_getObjectCostPath = "0102/"; 104 private static readonly string m_getObjectCostPath = "0102/";
105 private static readonly string m_ResourceCostSelectedPath = "0103/"; 105 private static readonly string m_ResourceCostSelectedPath = "0103/";
106 private static readonly string m_UpdateAgentInformationPath = "0500/";
106 107
107 108
108 // These are callbacks which will be setup by the scene so that we can update scene data when we 109 // These are callbacks which will be setup by the scene so that we can update scene data when we
@@ -287,6 +288,8 @@ namespace OpenSim.Region.ClientStack.Linden
287 m_HostCapsObj.RegisterHandler("GetObjectCost", getObjectCostHandler); 288 m_HostCapsObj.RegisterHandler("GetObjectCost", getObjectCostHandler);
288 IRequestHandler ResourceCostSelectedHandler = new RestStreamHandler("POST", capsBase + m_ResourceCostSelectedPath, ResourceCostSelected); 289 IRequestHandler ResourceCostSelectedHandler = new RestStreamHandler("POST", capsBase + m_ResourceCostSelectedPath, ResourceCostSelected);
289 m_HostCapsObj.RegisterHandler("ResourceCostSelected", ResourceCostSelectedHandler); 290 m_HostCapsObj.RegisterHandler("ResourceCostSelected", ResourceCostSelectedHandler);
291 IRequestHandler UpdateAgentInformationHandler = new RestStreamHandler("POST", capsBase + m_UpdateAgentInformationPath, UpdateAgentInformation);
292 m_HostCapsObj.RegisterHandler("UpdateAgentInformation", UpdateAgentInformationHandler);
290 293
291 m_HostCapsObj.RegisterHandler( 294 m_HostCapsObj.RegisterHandler(
292 "CopyInventoryFromNotecard", 295 "CopyInventoryFromNotecard",
@@ -1438,6 +1441,22 @@ namespace OpenSim.Region.ClientStack.Linden
1438 string response = OSDParser.SerializeLLSDXmlString(resp); 1441 string response = OSDParser.SerializeLLSDXmlString(resp);
1439 return response; 1442 return response;
1440 } 1443 }
1444
1445 public string UpdateAgentInformation(string request, string path,
1446 string param, IOSHttpRequest httpRequest,
1447 IOSHttpResponse httpResponse)
1448 {
1449 OSDMap req = (OSDMap)OSDParser.DeserializeLLSDXml(request);
1450 OSDMap resp = new OSDMap();
1451
1452 OSDMap accessPrefs = new OSDMap();
1453 accessPrefs["max"] = "A";
1454
1455 resp["access_prefs"] = accessPrefs;
1456
1457 string response = OSDParser.SerializeLLSDXmlString(resp);
1458 return response;
1459 }
1441 } 1460 }
1442 1461
1443 public class AssetUploader 1462 public class AssetUploader
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index 7ff30ca..faa92dc 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -2353,8 +2353,14 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
2353 { 2353 {
2354 m_host.AddScriptLPS(1); 2354 m_host.AddScriptLPS(1);
2355 2355
2356
2357 // Teravus: if (m_host.ParentID == 0) is bug code because the ParentID for the Avatar will cause this to be nonzero for root prim attachments
2358 // which is then treated like a child prim rotation and it's offset gets cumulatively multiplied against.
2359 // to fix the scripted rotations we also have to check to see if the root part localid is the same as the host's localid.
2360 // RootPart != null should shortcircuit
2361
2356 // try to let this work as in SL... 2362 // try to let this work as in SL...
2357 if (m_host.ParentID == 0) 2363 if (m_host.ParentID == 0 || (m_host.ParentGroup != null && m_host == m_host.ParentGroup.RootPart))
2358 { 2364 {
2359 // special case: If we are root, rotate complete SOG to new rotation 2365 // special case: If we are root, rotate complete SOG to new rotation
2360 SetRot(m_host, rot); 2366 SetRot(m_host, rot);
@@ -7911,7 +7917,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
7911 7917
7912 LSL_Rotation q = rules.GetQuaternionItem(idx++); 7918 LSL_Rotation q = rules.GetQuaternionItem(idx++);
7913 // try to let this work as in SL... 7919 // try to let this work as in SL...
7914 if (part.ParentID == 0) 7920 if (part.ParentID == 0 || (part.ParentGroup != null && part == part.ParentGroup.RootPart))
7915 { 7921 {
7916 // special case: If we are root, rotate complete SOG to new rotation 7922 // special case: If we are root, rotate complete SOG to new rotation
7917 SetRot(part, q); 7923 SetRot(part, q);
@@ -8744,11 +8750,13 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
8744 remaining = GetPrimParams(avatar, rules, ref res); 8750 remaining = GetPrimParams(avatar, rules, ref res);
8745 } 8751 }
8746 8752
8747 if (remaining != null && remaining.Length > 0) 8753 if ((object)remaining != null && remaining.Length > 0)
8748 { 8754 {
8749 linknumber = remaining.GetLSLIntegerItem(0); 8755 linknumber = remaining.GetLSLIntegerItem(0);
8750 rules = remaining.GetSublist(1, -1); 8756 rules = remaining.GetSublist(1, -1);
8751 } 8757 }
8758 else
8759 break;
8752 } 8760 }
8753 8761
8754 return res; 8762 return res;