aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
authorMelanie Thielker2010-09-05 14:16:42 +0200
committerMelanie2010-09-05 14:28:33 +0100
commit6a0a878f7c268c6f248588895e232e3d14eb6eb3 (patch)
tree19cf0fcd48035f34dee80fd07ce95f39bf486d99 /OpenSim/Region
parentLogout the presence if client IP verification fails. (diff)
downloadopensim-SC_OLD-6a0a878f7c268c6f248588895e232e3d14eb6eb3.zip
opensim-SC_OLD-6a0a878f7c268c6f248588895e232e3d14eb6eb3.tar.gz
opensim-SC_OLD-6a0a878f7c268c6f248588895e232e3d14eb6eb3.tar.bz2
opensim-SC_OLD-6a0a878f7c268c6f248588895e232e3d14eb6eb3.tar.xz
Remove "Dwell" support from core and replace it with calls to methods
on IDwellModule
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs6
-rw-r--r--OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs13
-rw-r--r--OpenSim/Region/DataSnapshot/LandSnapshot.cs7
3 files changed, 11 insertions, 15 deletions
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
index 3d4269f..9cdc80b 100644
--- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
+++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
@@ -2668,6 +2668,10 @@ namespace OpenSim.Region.ClientStack.LindenUDP
2668 2668
2669 public void SendParcelInfo(RegionInfo info, LandData land, UUID parcelID, uint x, uint y) 2669 public void SendParcelInfo(RegionInfo info, LandData land, UUID parcelID, uint x, uint y)
2670 { 2670 {
2671 float dwell = 0.0f;
2672 IDwellModule dwellModule = m_scene.RequestModuleInterface<IDwellModule>();
2673 if (dwellModule != null)
2674 dwell = dwellModule.GetDwell(land.GlobalID);
2671 ParcelInfoReplyPacket reply = (ParcelInfoReplyPacket)PacketPool.Instance.GetPacket(PacketType.ParcelInfoReply); 2675 ParcelInfoReplyPacket reply = (ParcelInfoReplyPacket)PacketPool.Instance.GetPacket(PacketType.ParcelInfoReply);
2672 reply.AgentData.AgentID = m_agentId; 2676 reply.AgentData.AgentID = m_agentId;
2673 reply.Data.ParcelID = parcelID; 2677 reply.Data.ParcelID = parcelID;
@@ -2692,7 +2696,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
2692 reply.Data.GlobalZ = pos.Z; 2696 reply.Data.GlobalZ = pos.Z;
2693 reply.Data.SimName = Utils.StringToBytes(info.RegionName); 2697 reply.Data.SimName = Utils.StringToBytes(info.RegionName);
2694 reply.Data.SnapshotID = land.SnapshotID; 2698 reply.Data.SnapshotID = land.SnapshotID;
2695 reply.Data.Dwell = land.Dwell; 2699 reply.Data.Dwell = dwell;
2696 reply.Data.SalePrice = land.SalePrice; 2700 reply.Data.SalePrice = land.SalePrice;
2697 reply.Data.AuctionID = (int)land.AuctionID; 2701 reply.Data.AuctionID = (int)land.AuctionID;
2698 2702
diff --git a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs
index 3e79ec0..268e2ee 100644
--- a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs
+++ b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs
@@ -163,7 +163,6 @@ namespace OpenSim.Region.CoreModules.World.Land
163 client.OnParcelGodForceOwner += ClientOnParcelGodForceOwner; 163 client.OnParcelGodForceOwner += ClientOnParcelGodForceOwner;
164 client.OnParcelReclaim += ClientOnParcelReclaim; 164 client.OnParcelReclaim += ClientOnParcelReclaim;
165 client.OnParcelInfoRequest += ClientOnParcelInfoRequest; 165 client.OnParcelInfoRequest += ClientOnParcelInfoRequest;
166 client.OnParcelDwellRequest += ClientOnParcelDwellRequest;
167 client.OnParcelDeedToGroup += ClientOnParcelDeedToGroup; 166 client.OnParcelDeedToGroup += ClientOnParcelDeedToGroup;
168 client.OnPreAgentUpdate += ClientOnPreAgentUpdate; 167 client.OnPreAgentUpdate += ClientOnPreAgentUpdate;
169 168
@@ -1487,18 +1486,6 @@ namespace OpenSim.Region.CoreModules.World.Land
1487 1486
1488 #endregion 1487 #endregion
1489 1488
1490 private void ClientOnParcelDwellRequest(int localID, IClientAPI remoteClient)
1491 {
1492 ILandObject selectedParcel = null;
1493 lock (m_landList)
1494 {
1495 if (!m_landList.TryGetValue(localID, out selectedParcel))
1496 return;
1497 }
1498
1499 remoteClient.SendParcelDwellReply(localID, selectedParcel.LandData.GlobalID, selectedParcel.LandData.Dwell);
1500 }
1501
1502 private void ClientOnParcelInfoRequest(IClientAPI remoteClient, UUID parcelID) 1489 private void ClientOnParcelInfoRequest(IClientAPI remoteClient, UUID parcelID)
1503 { 1490 {
1504 if (parcelID == UUID.Zero) 1491 if (parcelID == UUID.Zero)
diff --git a/OpenSim/Region/DataSnapshot/LandSnapshot.cs b/OpenSim/Region/DataSnapshot/LandSnapshot.cs
index 64d29f2..b8c90cd 100644
--- a/OpenSim/Region/DataSnapshot/LandSnapshot.cs
+++ b/OpenSim/Region/DataSnapshot/LandSnapshot.cs
@@ -123,6 +123,8 @@ namespace OpenSim.Region.DataSnapshot.Providers
123 ILandChannel landChannel = m_scene.LandChannel; 123 ILandChannel landChannel = m_scene.LandChannel;
124 List<ILandObject> parcels = landChannel.AllParcels(); 124 List<ILandObject> parcels = landChannel.AllParcels();
125 125
126 IDwellModule dwellModule = m_scene.RequestModuleInterface<IDwellModule>();
127
126 XmlNode parent = nodeFactory.CreateNode(XmlNodeType.Element, "parceldata", ""); 128 XmlNode parent = nodeFactory.CreateNode(XmlNodeType.Element, "parceldata", "");
127 if (parcels != null) 129 if (parcels != null)
128 { 130 {
@@ -208,7 +210,10 @@ namespace OpenSim.Region.DataSnapshot.Providers
208 xmlparcel.AppendChild(infouuid); 210 xmlparcel.AppendChild(infouuid);
209 211
210 XmlNode dwell = nodeFactory.CreateNode(XmlNodeType.Element, "dwell", ""); 212 XmlNode dwell = nodeFactory.CreateNode(XmlNodeType.Element, "dwell", "");
211 dwell.InnerText = parcel.Dwell.ToString(); 213 if (dwellModule != null)
214 dwell.InnerText = dwellModule.GetDwell(parcel.GlobalID).ToString();
215 else
216 dwell.InnerText = "0";
212 xmlparcel.AppendChild(dwell); 217 xmlparcel.AppendChild(dwell);
213 218
214 //TODO: figure how to figure out teleport system landData.landingType 219 //TODO: figure how to figure out teleport system landData.landingType