From 3d1f43046dd4d33c54e31ab103cd0866c8f417ac Mon Sep 17 00:00:00 2001
From: Dan Lake
Date: Tue, 24 Jan 2012 17:05:53 -0800
Subject: Removed unused delegates in SceneGraph: ObjectDuplicateDelegate,
ObjectCreateDelegate, ObjectDeleteDelegate
---
OpenSim/Region/Framework/Scenes/SceneGraph.cs | 6 ------
1 file changed, 6 deletions(-)
diff --git a/OpenSim/Region/Framework/Scenes/SceneGraph.cs b/OpenSim/Region/Framework/Scenes/SceneGraph.cs
index 1af8346..7f18140 100644
--- a/OpenSim/Region/Framework/Scenes/SceneGraph.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneGraph.cs
@@ -41,12 +41,6 @@ namespace OpenSim.Region.Framework.Scenes
{
public delegate void PhysicsCrash();
- public delegate void ObjectDuplicateDelegate(EntityBase original, EntityBase clone);
-
- public delegate void ObjectCreateDelegate(EntityBase obj);
-
- public delegate void ObjectDeleteDelegate(EntityBase obj);
-
///
/// This class used to be called InnerScene and may not yet truly be a SceneGraph. The non scene graph components
/// should be migrated out over time.
--
cgit v1.1
From 7c514fe155d6e0546f43c978804abadf11076777 Mon Sep 17 00:00:00 2001
From: BlueWall
Date: Tue, 24 Jan 2012 21:33:11 -0500
Subject: Telehub map items displayed
---
.../CoreModules/World/WorldMap/WorldMapModule.cs | 54 ++++++++++++++++++++--
1 file changed, 51 insertions(+), 3 deletions(-)
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs
index 2f723ef..81b433f 100644
--- a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs
+++ b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs
@@ -373,7 +373,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
public virtual void HandleMapItemRequest(IClientAPI remoteClient, uint flags,
uint EstateID, bool godlike, uint itemtype, ulong regionhandle)
{
-// m_log.DebugFormat("[WORLD MAP]: Handle MapItem request {0} {1}", regionhandle, itemtype);
+ m_log.DebugFormat("[WORLD MAP]: Handle MapItem request {0} {1}", regionhandle, itemtype);
lock (m_rootAgents)
{
@@ -429,7 +429,8 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
// ensures that the blockingqueue doesn't get borked if the GetAgents() timing changes.
RequestMapItems("",remoteClient.AgentId,flags,EstateID,godlike,itemtype,regionhandle);
}
- } else if (itemtype == 7) // Service 7 (MAP_ITEM_LAND_FOR_SALE)
+ }
+ else if (itemtype == 7) // Service 7 (MAP_ITEM_LAND_FOR_SALE)
{
if (regionhandle == 0 || regionhandle == m_scene.RegionInfo.RegionHandle)
{
@@ -481,6 +482,32 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
RequestMapItems("",remoteClient.AgentId,flags,EstateID,godlike,itemtype,regionhandle);
}
}
+ else if (itemtype == 1) // Service 1 (MAP_ITEM_TELEHUB)
+ {
+ if (regionhandle == 0 || regionhandle == m_scene.RegionInfo.RegionHandle)
+ {
+ List mapitems = new List();
+ mapItemReply mapitem = new mapItemReply();
+
+ SceneObjectPart sop = m_scene.GetSceneObjectPart(m_scene.RegionInfo.RegionSettings.TelehubObject);
+
+ mapitem = new mapItemReply();
+ mapitem.x = (uint)(xstart + sop.AbsolutePosition.X);
+ mapitem.y = (uint)(ystart + sop.AbsolutePosition.Y);
+ mapitem.id = UUID.Zero;
+ mapitem.name = sop.Name;
+ mapitem.Extra = 0; // color (not used)
+ mapitem.Extra2 = 0; // 0 = telehub / 1 = infohub
+ mapitems.Add(mapitem);
+
+ remoteClient.SendMapItemReply(mapitems.ToArray(), itemtype, flags);
+ }
+ else
+ {
+ // Remote Map Item Request
+ RequestMapItems("",remoteClient.AgentId,flags,EstateID,godlike,itemtype,regionhandle);
+ }
+ }
}
private int nAsyncRequests = 0;
@@ -620,6 +647,28 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
}
av.ControllingClient.SendMapItemReply(returnitems.ToArray(), itemtype, mrs.flags);
}
+
+ // Service 1 (MAP_ITEM_TELEHUB)
+ itemtype = 1;
+
+ if (response.ContainsKey(itemtype.ToString()))
+ {
+ List returnitems = new List();
+ OSDArray itemarray = (OSDArray)response[itemtype.ToString()];
+ for (int i = 0; i < itemarray.Count; i++)
+ {
+ OSDMap mapitem = (OSDMap)itemarray[i];
+ mapItemReply mi = new mapItemReply();
+ mi.x = (uint)mapitem["X"].AsInteger();
+ mi.y = (uint)mapitem["Y"].AsInteger();
+ mi.id = mapitem["ID"].AsUUID();
+ mi.Extra = mapitem["Extra"].AsInteger();
+ mi.Extra2 = mapitem["Extra2"].AsInteger();
+ mi.name = mapitem["Name"].AsString();
+ returnitems.Add(mi);
+ }
+ av.ControllingClient.SendMapItemReply(returnitems.ToArray(), itemtype, mrs.flags);
+ }
}
}
}
@@ -1258,7 +1307,6 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
OSDMap responsemapdata = new OSDMap();
responsemapdata["X"] = OSD.FromInteger((int)(xstart + sop.AbsolutePosition.X));
responsemapdata["Y"] = OSD.FromInteger((int)(ystart + sop.AbsolutePosition.Y));
- // responsemapdata["Z"] = OSD.FromInteger((int)m_scene.GetGroundHeight(x,y));
responsemapdata["ID"] = OSD.FromUUID(sop.UUID);
responsemapdata["Name"] = OSD.FromString(sop.Name);
responsemapdata["Extra"] = OSD.FromInteger(0); // color (unused)
--
cgit v1.1
From f84b69cad11fefa5f6615ed97170b8c12de2f3b4 Mon Sep 17 00:00:00 2001
From: Melanie
Date: Wed, 25 Jan 2012 15:00:06 +0000
Subject: Change the WorldMapModule to use SOG rather than SOP for the telehub
ans cover a potential nullref
---
.../CoreModules/World/WorldMap/WorldMapModule.cs | 28 ++++++++++++----------
1 file changed, 15 insertions(+), 13 deletions(-)
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs
index 2f723ef..af9c650 100644
--- a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs
+++ b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs
@@ -1252,20 +1252,22 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
if (m_scene.RegionInfo.RegionSettings.TelehubObject != UUID.Zero)
{
- SceneObjectPart sop = m_scene.GetSceneObjectPart(m_scene.RegionInfo.RegionSettings.TelehubObject);
-
- OSDArray responsearr = new OSDArray();
- OSDMap responsemapdata = new OSDMap();
- responsemapdata["X"] = OSD.FromInteger((int)(xstart + sop.AbsolutePosition.X));
- responsemapdata["Y"] = OSD.FromInteger((int)(ystart + sop.AbsolutePosition.Y));
- // responsemapdata["Z"] = OSD.FromInteger((int)m_scene.GetGroundHeight(x,y));
- responsemapdata["ID"] = OSD.FromUUID(sop.UUID);
- responsemapdata["Name"] = OSD.FromString(sop.Name);
- responsemapdata["Extra"] = OSD.FromInteger(0); // color (unused)
- responsemapdata["Extra2"] = OSD.FromInteger(0); // 0 = telehub / 1 = infohub
- responsearr.Add(responsemapdata);
+ SceneObjectGroup sog = m_scene.GetSceneObjectGroup(m_scene.RegionInfo.RegionSettings.TelehubObject);
+ if (sog != null)
+ {
+ OSDArray responsearr = new OSDArray();
+ OSDMap responsemapdata = new OSDMap();
+ responsemapdata["X"] = OSD.FromInteger((int)(xstart + sog.AbsolutePosition.X));
+ responsemapdata["Y"] = OSD.FromInteger((int)(ystart + sog.AbsolutePosition.Y));
+ // responsemapdata["Z"] = OSD.FromInteger((int)m_scene.GetGroundHeight(x,y));
+ responsemapdata["ID"] = OSD.FromUUID(sog.UUID);
+ responsemapdata["Name"] = OSD.FromString(sog.Name);
+ responsemapdata["Extra"] = OSD.FromInteger(0); // color (unused)
+ responsemapdata["Extra2"] = OSD.FromInteger(0); // 0 = telehub / 1 = infohub
+ responsearr.Add(responsemapdata);
- responsemap["1"] = responsearr;
+ responsemap["1"] = responsearr;
+ }
}
return responsemap;
--
cgit v1.1
From 8f53c768f53478ff3e0c27198b257bb27be16259 Mon Sep 17 00:00:00 2001
From: Pixel Tomsen
Date: Wed, 25 Jan 2012 21:31:18 +0100
Subject: llGetParcelMusicURL implementation
http://wiki.secondlife.com/wiki/LlGetParcelMusicURL
Signed-off-by: BlueWall
---
OpenSim/Framework/ILandObject.cs | 6 ++++++
OpenSim/Region/CoreModules/World/Land/LandObject.cs | 11 ++++++++++-
.../Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | 12 ++++++++++++
OpenSim/Region/ScriptEngine/Shared/Api/Interface/ILSL_Api.cs | 1 +
OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Stub.cs | 5 +++++
5 files changed, 34 insertions(+), 1 deletion(-)
diff --git a/OpenSim/Framework/ILandObject.cs b/OpenSim/Framework/ILandObject.cs
index 0316944..f75a990 100644
--- a/OpenSim/Framework/ILandObject.cs
+++ b/OpenSim/Framework/ILandObject.cs
@@ -130,5 +130,11 @@ namespace OpenSim.Framework
///
///
void SetMusicUrl(string url);
+
+ ///
+ /// Get the music url for this land parcel
+ ///
+ /// The music url.
+ string GetMusicUrl();
}
}
diff --git a/OpenSim/Region/CoreModules/World/Land/LandObject.cs b/OpenSim/Region/CoreModules/World/Land/LandObject.cs
index 0da0de3..79b13c3 100644
--- a/OpenSim/Region/CoreModules/World/Land/LandObject.cs
+++ b/OpenSim/Region/CoreModules/World/Land/LandObject.cs
@@ -1094,7 +1094,16 @@ namespace OpenSim.Region.CoreModules.World.Land
LandData.MusicURL = url;
SendLandUpdateToAvatarsOverMe();
}
-
+
+ ///
+ /// Get the music url for this land parcel
+ ///
+ /// The music url.
+ public string GetMusicUrl()
+ {
+ return LandData.MusicURL;
+ }
+
#endregion
}
}
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index fb930e0..330c65d 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -7566,6 +7566,18 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
ScriptSleep(2000);
}
+ public LSL_String llGetParcelMusicURL()
+ {
+ m_host.AddScriptLPS(1);
+
+ ILandObject land = World.LandChannel.GetLandObject(m_host.AbsolutePosition.X, m_host.AbsolutePosition.Y);
+
+ if (land.LandData.OwnerID != m_host.OwnerID)
+ return String.Empty;
+
+ return land.GetMusicUrl();
+ }
+
public LSL_Vector llGetRootPosition()
{
m_host.AddScriptLPS(1);
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Interface/ILSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Interface/ILSL_Api.cs
index 62e2854..282443b 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Interface/ILSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Interface/ILSL_Api.cs
@@ -161,6 +161,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Interfaces
LSL_List llGetParcelDetails(LSL_Vector pos, LSL_List param);
LSL_Integer llGetParcelFlags(LSL_Vector pos);
LSL_Integer llGetParcelMaxPrims(LSL_Vector pos, int sim_wide);
+ LSL_String llGetParcelMusicURL();
LSL_Integer llGetParcelPrimCount(LSL_Vector pos, int category, int sim_wide);
LSL_List llGetParcelPrimOwners(LSL_Vector pos);
LSL_Integer llGetPermissions();
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Stub.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Stub.cs
index 508f33b..9733683 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Stub.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Stub.cs
@@ -649,6 +649,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
return m_LSL_Functions.llGetParcelMaxPrims(pos, sim_wide);
}
+ public LSL_String llGetParcelMusicURL()
+ {
+ return m_LSL_Functions.llGetParcelMusicURL();
+ }
+
public LSL_Integer llGetParcelPrimCount(LSL_Vector pos, int category, int sim_wide)
{
return m_LSL_Functions.llGetParcelPrimCount(pos, category, sim_wide);
--
cgit v1.1