aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs2
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Friends/FriendsRequestHandler.cs2
-rw-r--r--OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs2
-rw-r--r--OpenSim/Region/CoreModules/Framework/UserManagement/UserManagementModule.cs2
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectorsIn/Land/LandServiceInConnectorModule.cs3
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectorsOut/Land/LocalLandServiceConnector.cs3
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectorsOut/Land/RemoteLandServiceConnector.cs7
-rw-r--r--OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs70
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.Permissions.cs61
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneCommunicationService.cs8
-rw-r--r--OpenSim/Server/Handlers/Land/LandHandlers.cs2
-rw-r--r--OpenSim/Services/Connectors/Land/LandServiceConnector.cs4
-rw-r--r--OpenSim/Services/Connectors/Neighbour/NeighbourServiceConnector.cs2
-rw-r--r--OpenSim/Services/Interfaces/ILandService.cs2
14 files changed, 113 insertions, 57 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs b/OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs
index b3f0a25..4d74b2a 100644
--- a/OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs
@@ -489,7 +489,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
489 im.imSessionID = im.fromAgentID; 489 im.imSessionID = im.fromAgentID;
490 490
491 // Try the local sim 491 // Try the local sim
492 UserAccount account = UserAccountService.GetUserAccount(Scene.RegionInfo.ScopeID, agentID); 492 UserAccount account = UserAccountService.GetUserAccount(UUID.Zero, agentID);
493 im.fromAgentName = (account == null) ? "Unknown" : account.FirstName + " " + account.LastName; 493 im.fromAgentName = (account == null) ? "Unknown" : account.FirstName + " " + account.LastName;
494 494
495 if (LocalFriendshipOffered(friendID, im)) 495 if (LocalFriendshipOffered(friendID, im))
diff --git a/OpenSim/Region/CoreModules/Avatar/Friends/FriendsRequestHandler.cs b/OpenSim/Region/CoreModules/Avatar/Friends/FriendsRequestHandler.cs
index 496f2ab..1b53a42 100644
--- a/OpenSim/Region/CoreModules/Avatar/Friends/FriendsRequestHandler.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Friends/FriendsRequestHandler.cs
@@ -116,7 +116,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
116 if (!UUID.TryParse(request["ToID"].ToString(), out toID)) 116 if (!UUID.TryParse(request["ToID"].ToString(), out toID))
117 return FailureResult(); 117 return FailureResult();
118 118
119 UserAccount account = m_FriendsModule.UserAccountService.GetUserAccount(m_FriendsModule.Scene.RegionInfo.ScopeID, fromID); 119 UserAccount account = m_FriendsModule.UserAccountService.GetUserAccount(UUID.Zero, fromID);
120 string name = (account == null) ? "Unknown" : account.FirstName + " " + account.LastName; 120 string name = (account == null) ? "Unknown" : account.FirstName + " " + account.LastName;
121 121
122 GridInstantMessage im = new GridInstantMessage(m_FriendsModule.Scene, fromID, name, toID, 122 GridInstantMessage im = new GridInstantMessage(m_FriendsModule.Scene, fromID, name, toID,
diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs
index a3251aa..e5cefe4 100644
--- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs
+++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs
@@ -1515,7 +1515,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
1515 // If we fail to cross the border, then reset the position of the scene object on that border. 1515 // If we fail to cross the border, then reset the position of the scene object on that border.
1516 uint x = 0, y = 0; 1516 uint x = 0, y = 0;
1517 Utils.LongToUInts(newRegionHandle, out x, out y); 1517 Utils.LongToUInts(newRegionHandle, out x, out y);
1518 GridRegion destination = scene.GridService.GetRegionByPosition(UUID.Zero, (int)x, (int)y); 1518 GridRegion destination = scene.GridService.GetRegionByPosition(scene.RegionInfo.ScopeID, (int)x, (int)y);
1519 if (destination != null && !CrossPrimGroupIntoNewRegion(destination, grp, silent)) 1519 if (destination != null && !CrossPrimGroupIntoNewRegion(destination, grp, silent))
1520 { 1520 {
1521 grp.OffsetForNewRegion(oldGroupPosition); 1521 grp.OffsetForNewRegion(oldGroupPosition);
diff --git a/OpenSim/Region/CoreModules/Framework/UserManagement/UserManagementModule.cs b/OpenSim/Region/CoreModules/Framework/UserManagement/UserManagementModule.cs
index bf84100..4cc6905 100644
--- a/OpenSim/Region/CoreModules/Framework/UserManagement/UserManagementModule.cs
+++ b/OpenSim/Region/CoreModules/Framework/UserManagement/UserManagementModule.cs
@@ -183,7 +183,7 @@ namespace OpenSim.Region.CoreModules.Framework.UserManagement
183 return returnstring; 183 return returnstring;
184 } 184 }
185 185
186 UserAccount account = m_Scenes[0].UserAccountService.GetUserAccount(m_Scenes[0].RegionInfo.ScopeID, uuid); 186 UserAccount account = m_Scenes[0].UserAccountService.GetUserAccount(UUID.Zero, uuid);
187 187
188 if (account != null) 188 if (account != null)
189 { 189 {
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsIn/Land/LandServiceInConnectorModule.cs b/OpenSim/Region/CoreModules/ServiceConnectorsIn/Land/LandServiceInConnectorModule.cs
index 23251c9..fcc69e9 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectorsIn/Land/LandServiceInConnectorModule.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectorsIn/Land/LandServiceInConnectorModule.cs
@@ -37,6 +37,7 @@ using OpenSim.Region.Framework.Interfaces;
37using OpenSim.Server.Base; 37using OpenSim.Server.Base;
38using OpenSim.Server.Handlers.Base; 38using OpenSim.Server.Handlers.Base;
39using OpenSim.Services.Interfaces; 39using OpenSim.Services.Interfaces;
40using OpenMetaverse;
40 41
41 42
42namespace OpenSim.Region.CoreModules.ServiceConnectorsIn.Land 43namespace OpenSim.Region.CoreModules.ServiceConnectorsIn.Land
@@ -121,7 +122,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsIn.Land
121 122
122 #region ILandService 123 #region ILandService
123 124
124 public LandData GetLandData(ulong regionHandle, uint x, uint y, out byte regionAccess) 125 public LandData GetLandData(UUID scopeID, ulong regionHandle, uint x, uint y, out byte regionAccess)
125 { 126 {
126 m_log.DebugFormat("[LAND IN CONNECTOR]: GetLandData for {0}. Count = {1}", 127 m_log.DebugFormat("[LAND IN CONNECTOR]: GetLandData for {0}. Count = {1}",
127 regionHandle, m_Scenes.Count); 128 regionHandle, m_Scenes.Count);
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Land/LocalLandServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Land/LocalLandServiceConnector.cs
index e15f624..86c0b85 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Land/LocalLandServiceConnector.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Land/LocalLandServiceConnector.cs
@@ -35,6 +35,7 @@ using OpenSim.Server.Base;
35using OpenSim.Region.Framework.Interfaces; 35using OpenSim.Region.Framework.Interfaces;
36using OpenSim.Region.Framework.Scenes; 36using OpenSim.Region.Framework.Scenes;
37using OpenSim.Services.Interfaces; 37using OpenSim.Services.Interfaces;
38using OpenMetaverse;
38 39
39namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Land 40namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Land
40{ 41{
@@ -116,7 +117,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Land
116 117
117 #region ILandService 118 #region ILandService
118 119
119 public LandData GetLandData(ulong regionHandle, uint x, uint y, out byte regionAccess) 120 public LandData GetLandData(UUID scopeID, ulong regionHandle, uint x, uint y, out byte regionAccess)
120 { 121 {
121 regionAccess = 2; 122 regionAccess = 2;
122 m_log.DebugFormat("[LAND CONNECTOR]: request for land data in {0} at {1}, {2}", 123 m_log.DebugFormat("[LAND CONNECTOR]: request for land data in {0} at {1}, {2}",
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Land/RemoteLandServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Land/RemoteLandServiceConnector.cs
index 252d9e7..766ef81 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Land/RemoteLandServiceConnector.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Land/RemoteLandServiceConnector.cs
@@ -36,6 +36,7 @@ using OpenSim.Region.Framework.Interfaces;
36using OpenSim.Region.Framework.Scenes; 36using OpenSim.Region.Framework.Scenes;
37using OpenSim.Services.Interfaces; 37using OpenSim.Services.Interfaces;
38using OpenSim.Server.Base; 38using OpenSim.Server.Base;
39using OpenMetaverse;
39 40
40 41
41namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Land 42namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Land
@@ -109,13 +110,13 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Land
109 110
110 #region ILandService 111 #region ILandService
111 112
112 public override LandData GetLandData(ulong regionHandle, uint x, uint y, out byte regionAccess) 113 public override LandData GetLandData(UUID scopeID, ulong regionHandle, uint x, uint y, out byte regionAccess)
113 { 114 {
114 LandData land = m_LocalService.GetLandData(regionHandle, x, y, out regionAccess); 115 LandData land = m_LocalService.GetLandData(scopeID, regionHandle, x, y, out regionAccess);
115 if (land != null) 116 if (land != null)
116 return land; 117 return land;
117 118
118 return base.GetLandData(regionHandle, x, y, out regionAccess); 119 return base.GetLandData(scopeID, regionHandle, x, y, out regionAccess);
119 120
120 } 121 }
121 #endregion ILandService 122 #endregion ILandService
diff --git a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs
index ac4705c..4f8e205 100644
--- a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs
+++ b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs
@@ -1510,40 +1510,40 @@ namespace OpenSim.Region.CoreModules.World.Land
1510 if (parcelID == UUID.Zero) 1510 if (parcelID == UUID.Zero)
1511 return; 1511 return;
1512 1512
1513 ExtendedLandData data = 1513 ExtendedLandData data = (ExtendedLandData)parcelInfoCache.Get(parcelID.ToString(),
1514 (ExtendedLandData)parcelInfoCache.Get(parcelID.ToString(), 1514 delegate(string id)
1515 delegate(string id) 1515 {
1516 { 1516 UUID parcel = UUID.Zero;
1517 UUID parcel = UUID.Zero; 1517 UUID.TryParse(id, out parcel);
1518 UUID.TryParse(id, out parcel); 1518 // assume we've got the parcelID we just computed in RemoteParcelRequest
1519 // assume we've got the parcelID we just computed in RemoteParcelRequest 1519 ExtendedLandData extLandData = new ExtendedLandData();
1520 ExtendedLandData extLandData = new ExtendedLandData(); 1520 Util.ParseFakeParcelID(parcel, out extLandData.RegionHandle,
1521 Util.ParseFakeParcelID(parcel, out extLandData.RegionHandle, 1521 out extLandData.X, out extLandData.Y);
1522 out extLandData.X, out extLandData.Y); 1522 m_log.DebugFormat("[LAND] got parcelinfo request for regionHandle {0}, x/y {1}/{2}",
1523 m_log.DebugFormat("[LAND] got parcelinfo request for regionHandle {0}, x/y {1}/{2}", 1523 extLandData.RegionHandle, extLandData.X, extLandData.Y);
1524 extLandData.RegionHandle, extLandData.X, extLandData.Y); 1524
1525 1525 // for this region or for somewhere else?
1526 // for this region or for somewhere else? 1526 if (extLandData.RegionHandle == m_scene.RegionInfo.RegionHandle)
1527 if (extLandData.RegionHandle == m_scene.RegionInfo.RegionHandle) 1527 {
1528 { 1528 extLandData.LandData = this.GetLandObject(extLandData.X, extLandData.Y).LandData;
1529 extLandData.LandData = this.GetLandObject(extLandData.X, extLandData.Y).LandData; 1529 extLandData.RegionAccess = m_scene.RegionInfo.AccessLevel;
1530 extLandData.RegionAccess = m_scene.RegionInfo.AccessLevel; 1530 }
1531 } 1531 else
1532 else 1532 {
1533 { 1533 ILandService landService = m_scene.RequestModuleInterface<ILandService>();
1534 ILandService landService = m_scene.RequestModuleInterface<ILandService>(); 1534 extLandData.LandData = landService.GetLandData(m_scene.RegionInfo.ScopeID,
1535 extLandData.LandData = landService.GetLandData(extLandData.RegionHandle, 1535 extLandData.RegionHandle,
1536 extLandData.X, 1536 extLandData.X,
1537 extLandData.Y, 1537 extLandData.Y,
1538 out extLandData.RegionAccess); 1538 out extLandData.RegionAccess);
1539 if (extLandData.LandData == null) 1539 if (extLandData.LandData == null)
1540 { 1540 {
1541 // we didn't find the region/land => don't cache 1541 // we didn't find the region/land => don't cache
1542 return null; 1542 return null;
1543 } 1543 }
1544 } 1544 }
1545 return extLandData; 1545 return extLandData;
1546 }); 1546 });
1547 1547
1548 if (data != null) // if we found some data, send it 1548 if (data != null) // if we found some data, send it
1549 { 1549 {
@@ -1557,7 +1557,7 @@ namespace OpenSim.Region.CoreModules.World.Land
1557 // most likely still cached from building the extLandData entry 1557 // most likely still cached from building the extLandData entry
1558 uint x = 0, y = 0; 1558 uint x = 0, y = 0;
1559 Utils.LongToUInts(data.RegionHandle, out x, out y); 1559 Utils.LongToUInts(data.RegionHandle, out x, out y);
1560 info = m_scene.GridService.GetRegionByPosition(UUID.Zero, (int)x, (int)y); 1560 info = m_scene.GridService.GetRegionByPosition(m_scene.RegionInfo.ScopeID, (int)x, (int)y);
1561 } 1561 }
1562 // we need to transfer the fake parcelID, not the one in landData, so the viewer can match it to the landmark. 1562 // we need to transfer the fake parcelID, not the one in landData, so the viewer can match it to the landmark.
1563 m_log.DebugFormat("[LAND] got parcelinfo for parcel {0} in region {1}; sending...", 1563 m_log.DebugFormat("[LAND] got parcelinfo for parcel {0} in region {1}; sending...",
diff --git a/OpenSim/Region/Framework/Scenes/Scene.Permissions.cs b/OpenSim/Region/Framework/Scenes/Scene.Permissions.cs
index 66439ab..e1fedf4 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.Permissions.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.Permissions.cs
@@ -43,6 +43,7 @@ namespace OpenSim.Region.Framework.Scenes
43 public delegate bool PropagatePermissionsHandler(); 43 public delegate bool PropagatePermissionsHandler();
44 public delegate bool RezObjectHandler(int objectCount, UUID owner, Vector3 objectPosition, Scene scene); 44 public delegate bool RezObjectHandler(int objectCount, UUID owner, Vector3 objectPosition, Scene scene);
45 public delegate bool DeleteObjectHandler(UUID objectID, UUID deleter, Scene scene); 45 public delegate bool DeleteObjectHandler(UUID objectID, UUID deleter, Scene scene);
46 public delegate bool TransferObjectHandler(UUID objectID, UUID recipient, Scene scene);
46 public delegate bool TakeObjectHandler(UUID objectID, UUID stealer, Scene scene); 47 public delegate bool TakeObjectHandler(UUID objectID, UUID stealer, Scene scene);
47 public delegate bool TakeCopyObjectHandler(UUID objectID, UUID userID, Scene inScene); 48 public delegate bool TakeCopyObjectHandler(UUID objectID, UUID userID, Scene inScene);
48 public delegate bool DuplicateObjectHandler(int objectCount, UUID objectID, UUID owner, Scene scene, Vector3 objectPosition); 49 public delegate bool DuplicateObjectHandler(int objectCount, UUID objectID, UUID owner, Scene scene, Vector3 objectPosition);
@@ -80,10 +81,12 @@ namespace OpenSim.Region.Framework.Scenes
80 public delegate bool CreateObjectInventoryHandler(int invType, UUID objectID, UUID userID); 81 public delegate bool CreateObjectInventoryHandler(int invType, UUID objectID, UUID userID);
81 public delegate bool CopyObjectInventoryHandler(UUID itemID, UUID objectID, UUID userID); 82 public delegate bool CopyObjectInventoryHandler(UUID itemID, UUID objectID, UUID userID);
82 public delegate bool DeleteObjectInventoryHandler(UUID itemID, UUID objectID, UUID userID); 83 public delegate bool DeleteObjectInventoryHandler(UUID itemID, UUID objectID, UUID userID);
84 public delegate bool TransferObjectInventoryHandler(UUID itemID, UUID objectID, UUID userID);
83 public delegate bool CreateUserInventoryHandler(int invType, UUID userID); 85 public delegate bool CreateUserInventoryHandler(int invType, UUID userID);
84 public delegate bool EditUserInventoryHandler(UUID itemID, UUID userID); 86 public delegate bool EditUserInventoryHandler(UUID itemID, UUID userID);
85 public delegate bool CopyUserInventoryHandler(UUID itemID, UUID userID); 87 public delegate bool CopyUserInventoryHandler(UUID itemID, UUID userID);
86 public delegate bool DeleteUserInventoryHandler(UUID itemID, UUID userID); 88 public delegate bool DeleteUserInventoryHandler(UUID itemID, UUID userID);
89 public delegate bool TransferUserInventoryHandler(UUID itemID, UUID userID, UUID recipientID);
87 public delegate bool TeleportHandler(UUID userID, Scene scene); 90 public delegate bool TeleportHandler(UUID userID, Scene scene);
88 public delegate bool ControlPrimMediaHandler(UUID userID, UUID primID, int face); 91 public delegate bool ControlPrimMediaHandler(UUID userID, UUID primID, int face);
89 public delegate bool InteractWithPrimMediaHandler(UUID userID, UUID primID, int face); 92 public delegate bool InteractWithPrimMediaHandler(UUID userID, UUID primID, int face);
@@ -107,6 +110,7 @@ namespace OpenSim.Region.Framework.Scenes
107 public event PropagatePermissionsHandler OnPropagatePermissions; 110 public event PropagatePermissionsHandler OnPropagatePermissions;
108 public event RezObjectHandler OnRezObject; 111 public event RezObjectHandler OnRezObject;
109 public event DeleteObjectHandler OnDeleteObject; 112 public event DeleteObjectHandler OnDeleteObject;
113 public event TransferObjectHandler OnTransferObject;
110 public event TakeObjectHandler OnTakeObject; 114 public event TakeObjectHandler OnTakeObject;
111 public event TakeCopyObjectHandler OnTakeCopyObject; 115 public event TakeCopyObjectHandler OnTakeCopyObject;
112 public event DuplicateObjectHandler OnDuplicateObject; 116 public event DuplicateObjectHandler OnDuplicateObject;
@@ -144,10 +148,12 @@ namespace OpenSim.Region.Framework.Scenes
144 public event CreateObjectInventoryHandler OnCreateObjectInventory; 148 public event CreateObjectInventoryHandler OnCreateObjectInventory;
145 public event CopyObjectInventoryHandler OnCopyObjectInventory; 149 public event CopyObjectInventoryHandler OnCopyObjectInventory;
146 public event DeleteObjectInventoryHandler OnDeleteObjectInventory; 150 public event DeleteObjectInventoryHandler OnDeleteObjectInventory;
151 public event TransferObjectInventoryHandler OnTransferObjectInventory;
147 public event CreateUserInventoryHandler OnCreateUserInventory; 152 public event CreateUserInventoryHandler OnCreateUserInventory;
148 public event EditUserInventoryHandler OnEditUserInventory; 153 public event EditUserInventoryHandler OnEditUserInventory;
149 public event CopyUserInventoryHandler OnCopyUserInventory; 154 public event CopyUserInventoryHandler OnCopyUserInventory;
150 public event DeleteUserInventoryHandler OnDeleteUserInventory; 155 public event DeleteUserInventoryHandler OnDeleteUserInventory;
156 public event TransferUserInventoryHandler OnTransferUserInventory;
151 public event TeleportHandler OnTeleport; 157 public event TeleportHandler OnTeleport;
152 public event ControlPrimMediaHandler OnControlPrimMedia; 158 public event ControlPrimMediaHandler OnControlPrimMedia;
153 public event InteractWithPrimMediaHandler OnInteractWithPrimMedia; 159 public event InteractWithPrimMediaHandler OnInteractWithPrimMedia;
@@ -264,10 +270,27 @@ namespace OpenSim.Region.Framework.Scenes
264 } 270 }
265 } 271 }
266 272
267// m_log.DebugFormat( 273 return result;
268// "[SCENE PERMISSIONS]: CanDeleteObject() fired for object {0}, deleter {1}, result {2}", 274 }
269// objectID, deleter, result); 275
270 276 public bool CanTransferObject(UUID objectID, UUID recipient)
277 {
278 bool result = true;
279
280 TransferObjectHandler handler = OnTransferObject;
281 if (handler != null)
282 {
283 Delegate[] list = handler.GetInvocationList();
284 foreach (TransferObjectHandler h in list)
285 {
286 if (h(objectID, recipient, m_scene) == false)
287 {
288 result = false;
289 break;
290 }
291 }
292 }
293
271 return result; 294 return result;
272 } 295 }
273 296
@@ -917,6 +940,21 @@ namespace OpenSim.Region.Framework.Scenes
917 return true; 940 return true;
918 } 941 }
919 942
943 public bool CanTransferObjectInventory(UUID itemID, UUID objectID, UUID userID)
944 {
945 TransferObjectInventoryHandler handler = OnTransferObjectInventory;
946 if (handler != null)
947 {
948 Delegate[] list = handler.GetInvocationList();
949 foreach (TransferObjectInventoryHandler h in list)
950 {
951 if (h(itemID, objectID, userID) == false)
952 return false;
953 }
954 }
955 return true;
956 }
957
920 /// <summary> 958 /// <summary>
921 /// Check whether the specified user is allowed to create the given inventory type in their inventory. 959 /// Check whether the specified user is allowed to create the given inventory type in their inventory.
922 /// </summary> 960 /// </summary>
@@ -1001,6 +1039,21 @@ namespace OpenSim.Region.Framework.Scenes
1001 return true; 1039 return true;
1002 } 1040 }
1003 1041
1042 public bool CanTransferUserInventory(UUID itemID, UUID userID, UUID recipientID)
1043 {
1044 TransferUserInventoryHandler handler = OnTransferUserInventory;
1045 if (handler != null)
1046 {
1047 Delegate[] list = handler.GetInvocationList();
1048 foreach (TransferUserInventoryHandler h in list)
1049 {
1050 if (h(itemID, userID, recipientID) == false)
1051 return false;
1052 }
1053 }
1054 return true;
1055 }
1056
1004 public bool CanTeleport(UUID userID) 1057 public bool CanTeleport(UUID userID)
1005 { 1058 {
1006 TeleportHandler handler = OnTeleport; 1059 TeleportHandler handler = OnTeleport;
diff --git a/OpenSim/Region/Framework/Scenes/SceneCommunicationService.cs b/OpenSim/Region/Framework/Scenes/SceneCommunicationService.cs
index 88e084e..69ebe9e 100644
--- a/OpenSim/Region/Framework/Scenes/SceneCommunicationService.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneCommunicationService.cs
@@ -193,7 +193,7 @@ namespace OpenSim.Region.Framework.Scenes
193 } 193 }
194 } 194 }
195 195
196 public delegate void SendChildAgentDataUpdateDelegate(AgentPosition cAgentData, ulong regionHandle); 196 public delegate void SendChildAgentDataUpdateDelegate(AgentPosition cAgentData, UUID scopeID, ulong regionHandle);
197 197
198 /// <summary> 198 /// <summary>
199 /// This informs all neighboring regions about the settings of it's child agent. 199 /// This informs all neighboring regions about the settings of it's child agent.
@@ -202,7 +202,7 @@ namespace OpenSim.Region.Framework.Scenes
202 /// This contains information, such as, Draw Distance, Camera location, Current Position, Current throttle settings, etc. 202 /// This contains information, such as, Draw Distance, Camera location, Current Position, Current throttle settings, etc.
203 /// 203 ///
204 /// </summary> 204 /// </summary>
205 private void SendChildAgentDataUpdateAsync(AgentPosition cAgentData, ulong regionHandle) 205 private void SendChildAgentDataUpdateAsync(AgentPosition cAgentData, UUID scopeID, ulong regionHandle)
206 { 206 {
207 //m_log.Info("[INTERGRID]: Informing neighbors about my agent in " + m_regionInfo.RegionName); 207 //m_log.Info("[INTERGRID]: Informing neighbors about my agent in " + m_regionInfo.RegionName);
208 try 208 try
@@ -245,7 +245,7 @@ namespace OpenSim.Region.Framework.Scenes
245 if (regionHandle != m_regionInfo.RegionHandle) 245 if (regionHandle != m_regionInfo.RegionHandle)
246 { 246 {
247 SendChildAgentDataUpdateDelegate d = SendChildAgentDataUpdateAsync; 247 SendChildAgentDataUpdateDelegate d = SendChildAgentDataUpdateAsync;
248 d.BeginInvoke(cAgentData, regionHandle, 248 d.BeginInvoke(cAgentData, m_regionInfo.ScopeID, regionHandle,
249 SendChildAgentDataUpdateCompleted, 249 SendChildAgentDataUpdateCompleted,
250 d); 250 d);
251 } 251 }
@@ -273,7 +273,7 @@ namespace OpenSim.Region.Framework.Scenes
273 //m_commsProvider.InterRegion.TellRegionToCloseChildConnection(regionHandle, agentID); 273 //m_commsProvider.InterRegion.TellRegionToCloseChildConnection(regionHandle, agentID);
274 uint x = 0, y = 0; 274 uint x = 0, y = 0;
275 Utils.LongToUInts(regionHandle, out x, out y); 275 Utils.LongToUInts(regionHandle, out x, out y);
276 GridRegion destination = m_scene.GridService.GetRegionByPosition(UUID.Zero, (int)x, (int)y); 276 GridRegion destination = m_scene.GridService.GetRegionByPosition(m_regionInfo.ScopeID, (int)x, (int)y);
277 m_scene.SimulationService.CloseAgent(destination, agentID); 277 m_scene.SimulationService.CloseAgent(destination, agentID);
278 } 278 }
279 279
diff --git a/OpenSim/Server/Handlers/Land/LandHandlers.cs b/OpenSim/Server/Handlers/Land/LandHandlers.cs
index 561f285..b45289a 100644
--- a/OpenSim/Server/Handlers/Land/LandHandlers.cs
+++ b/OpenSim/Server/Handlers/Land/LandHandlers.cs
@@ -67,7 +67,7 @@ namespace OpenSim.Server.Handlers.Land
67 m_log.DebugFormat("[LAND HANDLER]: Got request for land data at {0}, {1} for region {2}", x, y, regionHandle); 67 m_log.DebugFormat("[LAND HANDLER]: Got request for land data at {0}, {1} for region {2}", x, y, regionHandle);
68 68
69 byte regionAccess; 69 byte regionAccess;
70 LandData landData = m_LocalService.GetLandData(regionHandle, x, y, out regionAccess); 70 LandData landData = m_LocalService.GetLandData(UUID.Zero, regionHandle, x, y, out regionAccess);
71 Hashtable hash = new Hashtable(); 71 Hashtable hash = new Hashtable();
72 if (landData != null) 72 if (landData != null)
73 { 73 {
diff --git a/OpenSim/Services/Connectors/Land/LandServiceConnector.cs b/OpenSim/Services/Connectors/Land/LandServiceConnector.cs
index 4b25ac8..252f7a1 100644
--- a/OpenSim/Services/Connectors/Land/LandServiceConnector.cs
+++ b/OpenSim/Services/Connectors/Land/LandServiceConnector.cs
@@ -64,7 +64,7 @@ namespace OpenSim.Services.Connectors
64 m_GridService = gridServices; 64 m_GridService = gridServices;
65 } 65 }
66 66
67 public virtual LandData GetLandData(ulong regionHandle, uint x, uint y, out byte regionAccess) 67 public virtual LandData GetLandData(UUID scopeID, ulong regionHandle, uint x, uint y, out byte regionAccess)
68 { 68 {
69 LandData landData = null; 69 LandData landData = null;
70 Hashtable hash = new Hashtable(); 70 Hashtable hash = new Hashtable();
@@ -80,7 +80,7 @@ namespace OpenSim.Services.Connectors
80 { 80 {
81 uint xpos = 0, ypos = 0; 81 uint xpos = 0, ypos = 0;
82 Utils.LongToUInts(regionHandle, out xpos, out ypos); 82 Utils.LongToUInts(regionHandle, out xpos, out ypos);
83 GridRegion info = m_GridService.GetRegionByPosition(UUID.Zero, (int)xpos, (int)ypos); 83 GridRegion info = m_GridService.GetRegionByPosition(scopeID, (int)xpos, (int)ypos);
84 if (info != null) // just to be sure 84 if (info != null) // just to be sure
85 { 85 {
86 XmlRpcRequest request = new XmlRpcRequest("land_data", paramList); 86 XmlRpcRequest request = new XmlRpcRequest("land_data", paramList);
diff --git a/OpenSim/Services/Connectors/Neighbour/NeighbourServiceConnector.cs b/OpenSim/Services/Connectors/Neighbour/NeighbourServiceConnector.cs
index 93da10e..9e444c4 100644
--- a/OpenSim/Services/Connectors/Neighbour/NeighbourServiceConnector.cs
+++ b/OpenSim/Services/Connectors/Neighbour/NeighbourServiceConnector.cs
@@ -71,7 +71,7 @@ namespace OpenSim.Services.Connectors
71 { 71 {
72 uint x = 0, y = 0; 72 uint x = 0, y = 0;
73 Utils.LongToUInts(regionHandle, out x, out y); 73 Utils.LongToUInts(regionHandle, out x, out y);
74 GridRegion regInfo = m_GridService.GetRegionByPosition(UUID.Zero, (int)x, (int)y); 74 GridRegion regInfo = m_GridService.GetRegionByPosition(thisRegion.ScopeID, (int)x, (int)y);
75 if ((regInfo != null) && 75 if ((regInfo != null) &&
76 // Don't remote-call this instance; that's a startup hickup 76 // Don't remote-call this instance; that's a startup hickup
77 !((regInfo.ExternalHostName == thisRegion.ExternalHostName) && (regInfo.HttpPort == thisRegion.HttpPort))) 77 !((regInfo.ExternalHostName == thisRegion.ExternalHostName) && (regInfo.HttpPort == thisRegion.HttpPort)))
diff --git a/OpenSim/Services/Interfaces/ILandService.cs b/OpenSim/Services/Interfaces/ILandService.cs
index 7a12aff..63d9a27 100644
--- a/OpenSim/Services/Interfaces/ILandService.cs
+++ b/OpenSim/Services/Interfaces/ILandService.cs
@@ -33,6 +33,6 @@ namespace OpenSim.Services.Interfaces
33{ 33{
34 public interface ILandService 34 public interface ILandService
35 { 35 {
36 LandData GetLandData(ulong regionHandle, uint x, uint y, out byte regionAccess); 36 LandData GetLandData(UUID scopeID, ulong regionHandle, uint x, uint y, out byte regionAccess);
37 } 37 }
38} 38}