aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Framework/ILandObject.cs6
-rw-r--r--OpenSim/Region/CoreModules/World/Land/LandObject.cs11
-rw-r--r--OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs81
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneGraph.cs6
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs12
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Interface/ILSL_Api.cs1
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Stub.cs5
7 files changed, 100 insertions, 22 deletions
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
130 /// </summary> 130 /// </summary>
131 /// <param name="url"></param> 131 /// <param name="url"></param>
132 void SetMusicUrl(string url); 132 void SetMusicUrl(string url);
133
134 /// <summary>
135 /// Get the music url for this land parcel
136 /// </summary>
137 /// <returns>The music url.</returns>
138 string GetMusicUrl();
133 } 139 }
134} 140}
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
1094 LandData.MusicURL = url; 1094 LandData.MusicURL = url;
1095 SendLandUpdateToAvatarsOverMe(); 1095 SendLandUpdateToAvatarsOverMe();
1096 } 1096 }
1097 1097
1098 /// <summary>
1099 /// Get the music url for this land parcel
1100 /// </summary>
1101 /// <returns>The music url.</returns>
1102 public string GetMusicUrl()
1103 {
1104 return LandData.MusicURL;
1105 }
1106
1098 #endregion 1107 #endregion
1099 } 1108 }
1100} 1109}
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs
index 2f723ef..1a9313b 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
373 public virtual void HandleMapItemRequest(IClientAPI remoteClient, uint flags, 373 public virtual void HandleMapItemRequest(IClientAPI remoteClient, uint flags,
374 uint EstateID, bool godlike, uint itemtype, ulong regionhandle) 374 uint EstateID, bool godlike, uint itemtype, ulong regionhandle)
375 { 375 {
376// m_log.DebugFormat("[WORLD MAP]: Handle MapItem request {0} {1}", regionhandle, itemtype); 376 m_log.DebugFormat("[WORLD MAP]: Handle MapItem request {0} {1}", regionhandle, itemtype);
377 377
378 lock (m_rootAgents) 378 lock (m_rootAgents)
379 { 379 {
@@ -429,7 +429,8 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
429 // ensures that the blockingqueue doesn't get borked if the GetAgents() timing changes. 429 // ensures that the blockingqueue doesn't get borked if the GetAgents() timing changes.
430 RequestMapItems("",remoteClient.AgentId,flags,EstateID,godlike,itemtype,regionhandle); 430 RequestMapItems("",remoteClient.AgentId,flags,EstateID,godlike,itemtype,regionhandle);
431 } 431 }
432 } else if (itemtype == 7) // Service 7 (MAP_ITEM_LAND_FOR_SALE) 432 }
433 else if (itemtype == 7) // Service 7 (MAP_ITEM_LAND_FOR_SALE)
433 { 434 {
434 if (regionhandle == 0 || regionhandle == m_scene.RegionInfo.RegionHandle) 435 if (regionhandle == 0 || regionhandle == m_scene.RegionInfo.RegionHandle)
435 { 436 {
@@ -481,6 +482,32 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
481 RequestMapItems("",remoteClient.AgentId,flags,EstateID,godlike,itemtype,regionhandle); 482 RequestMapItems("",remoteClient.AgentId,flags,EstateID,godlike,itemtype,regionhandle);
482 } 483 }
483 } 484 }
485 else if (itemtype == 1) // Service 1 (MAP_ITEM_TELEHUB)
486 {
487 if (regionhandle == 0 || regionhandle == m_scene.RegionInfo.RegionHandle)
488 {
489 List<mapItemReply> mapitems = new List<mapItemReply>();
490 mapItemReply mapitem = new mapItemReply();
491
492 SceneObjectPart sop = m_scene.GetSceneObjectPart(m_scene.RegionInfo.RegionSettings.TelehubObject);
493
494 mapitem = new mapItemReply();
495 mapitem.x = (uint)(xstart + sop.AbsolutePosition.X);
496 mapitem.y = (uint)(ystart + sop.AbsolutePosition.Y);
497 mapitem.id = UUID.Zero;
498 mapitem.name = sop.Name;
499 mapitem.Extra = 0; // color (not used)
500 mapitem.Extra2 = 0; // 0 = telehub / 1 = infohub
501 mapitems.Add(mapitem);
502
503 remoteClient.SendMapItemReply(mapitems.ToArray(), itemtype, flags);
504 }
505 else
506 {
507 // Remote Map Item Request
508 RequestMapItems("",remoteClient.AgentId,flags,EstateID,godlike,itemtype,regionhandle);
509 }
510 }
484 } 511 }
485 512
486 private int nAsyncRequests = 0; 513 private int nAsyncRequests = 0;
@@ -620,6 +647,28 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
620 } 647 }
621 av.ControllingClient.SendMapItemReply(returnitems.ToArray(), itemtype, mrs.flags); 648 av.ControllingClient.SendMapItemReply(returnitems.ToArray(), itemtype, mrs.flags);
622 } 649 }
650
651 // Service 1 (MAP_ITEM_TELEHUB)
652 itemtype = 1;
653
654 if (response.ContainsKey(itemtype.ToString()))
655 {
656 List<mapItemReply> returnitems = new List<mapItemReply>();
657 OSDArray itemarray = (OSDArray)response[itemtype.ToString()];
658 for (int i = 0; i < itemarray.Count; i++)
659 {
660 OSDMap mapitem = (OSDMap)itemarray[i];
661 mapItemReply mi = new mapItemReply();
662 mi.x = (uint)mapitem["X"].AsInteger();
663 mi.y = (uint)mapitem["Y"].AsInteger();
664 mi.id = mapitem["ID"].AsUUID();
665 mi.Extra = mapitem["Extra"].AsInteger();
666 mi.Extra2 = mapitem["Extra2"].AsInteger();
667 mi.name = mapitem["Name"].AsString();
668 returnitems.Add(mi);
669 }
670 av.ControllingClient.SendMapItemReply(returnitems.ToArray(), itemtype, mrs.flags);
671 }
623 } 672 }
624 } 673 }
625 } 674 }
@@ -1252,20 +1301,22 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
1252 1301
1253 if (m_scene.RegionInfo.RegionSettings.TelehubObject != UUID.Zero) 1302 if (m_scene.RegionInfo.RegionSettings.TelehubObject != UUID.Zero)
1254 { 1303 {
1255 SceneObjectPart sop = m_scene.GetSceneObjectPart(m_scene.RegionInfo.RegionSettings.TelehubObject); 1304 SceneObjectGroup sog = m_scene.GetSceneObjectGroup(m_scene.RegionInfo.RegionSettings.TelehubObject);
1256 1305 if (sog != null)
1257 OSDArray responsearr = new OSDArray(); 1306 {
1258 OSDMap responsemapdata = new OSDMap(); 1307 OSDArray responsearr = new OSDArray();
1259 responsemapdata["X"] = OSD.FromInteger((int)(xstart + sop.AbsolutePosition.X)); 1308 OSDMap responsemapdata = new OSDMap();
1260 responsemapdata["Y"] = OSD.FromInteger((int)(ystart + sop.AbsolutePosition.Y)); 1309 responsemapdata["X"] = OSD.FromInteger((int)(xstart + sog.AbsolutePosition.X));
1261 // responsemapdata["Z"] = OSD.FromInteger((int)m_scene.GetGroundHeight(x,y)); 1310 responsemapdata["Y"] = OSD.FromInteger((int)(ystart + sog.AbsolutePosition.Y));
1262 responsemapdata["ID"] = OSD.FromUUID(sop.UUID); 1311 // responsemapdata["Z"] = OSD.FromInteger((int)m_scene.GetGroundHeight(x,y));
1263 responsemapdata["Name"] = OSD.FromString(sop.Name); 1312 responsemapdata["ID"] = OSD.FromUUID(sog.UUID);
1264 responsemapdata["Extra"] = OSD.FromInteger(0); // color (unused) 1313 responsemapdata["Name"] = OSD.FromString(sog.Name);
1265 responsemapdata["Extra2"] = OSD.FromInteger(0); // 0 = telehub / 1 = infohub 1314 responsemapdata["Extra"] = OSD.FromInteger(0); // color (unused)
1266 responsearr.Add(responsemapdata); 1315 responsemapdata["Extra2"] = OSD.FromInteger(0); // 0 = telehub / 1 = infohub
1316 responsearr.Add(responsemapdata);
1267 1317
1268 responsemap["1"] = responsearr; 1318 responsemap["1"] = responsearr;
1319 }
1269 } 1320 }
1270 1321
1271 return responsemap; 1322 return responsemap;
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
41{ 41{
42 public delegate void PhysicsCrash(); 42 public delegate void PhysicsCrash();
43 43
44 public delegate void ObjectDuplicateDelegate(EntityBase original, EntityBase clone);
45
46 public delegate void ObjectCreateDelegate(EntityBase obj);
47
48 public delegate void ObjectDeleteDelegate(EntityBase obj);
49
50 /// <summary> 44 /// <summary>
51 /// This class used to be called InnerScene and may not yet truly be a SceneGraph. The non scene graph components 45 /// This class used to be called InnerScene and may not yet truly be a SceneGraph. The non scene graph components
52 /// should be migrated out over time. 46 /// should be migrated out over time.
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
7566 ScriptSleep(2000); 7566 ScriptSleep(2000);
7567 } 7567 }
7568 7568
7569 public LSL_String llGetParcelMusicURL()
7570 {
7571 m_host.AddScriptLPS(1);
7572
7573 ILandObject land = World.LandChannel.GetLandObject(m_host.AbsolutePosition.X, m_host.AbsolutePosition.Y);
7574
7575 if (land.LandData.OwnerID != m_host.OwnerID)
7576 return String.Empty;
7577
7578 return land.GetMusicUrl();
7579 }
7580
7569 public LSL_Vector llGetRootPosition() 7581 public LSL_Vector llGetRootPosition()
7570 { 7582 {
7571 m_host.AddScriptLPS(1); 7583 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
161 LSL_List llGetParcelDetails(LSL_Vector pos, LSL_List param); 161 LSL_List llGetParcelDetails(LSL_Vector pos, LSL_List param);
162 LSL_Integer llGetParcelFlags(LSL_Vector pos); 162 LSL_Integer llGetParcelFlags(LSL_Vector pos);
163 LSL_Integer llGetParcelMaxPrims(LSL_Vector pos, int sim_wide); 163 LSL_Integer llGetParcelMaxPrims(LSL_Vector pos, int sim_wide);
164 LSL_String llGetParcelMusicURL();
164 LSL_Integer llGetParcelPrimCount(LSL_Vector pos, int category, int sim_wide); 165 LSL_Integer llGetParcelPrimCount(LSL_Vector pos, int category, int sim_wide);
165 LSL_List llGetParcelPrimOwners(LSL_Vector pos); 166 LSL_List llGetParcelPrimOwners(LSL_Vector pos);
166 LSL_Integer llGetPermissions(); 167 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
649 return m_LSL_Functions.llGetParcelMaxPrims(pos, sim_wide); 649 return m_LSL_Functions.llGetParcelMaxPrims(pos, sim_wide);
650 } 650 }
651 651
652 public LSL_String llGetParcelMusicURL()
653 {
654 return m_LSL_Functions.llGetParcelMusicURL();
655 }
656
652 public LSL_Integer llGetParcelPrimCount(LSL_Vector pos, int category, int sim_wide) 657 public LSL_Integer llGetParcelPrimCount(LSL_Vector pos, int category, int sim_wide)
653 { 658 {
654 return m_LSL_Functions.llGetParcelPrimCount(pos, category, sim_wide); 659 return m_LSL_Functions.llGetParcelPrimCount(pos, category, sim_wide);