aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
authorTeravus Ovares2008-02-09 07:53:01 +0000
committerTeravus Ovares2008-02-09 07:53:01 +0000
commit07d0f558c441a0936441ed23ed076cf54a0dc578 (patch)
treeb63c06f8975b904c1e792647b7e0bc045dfe2e7c /OpenSim/Region
parentMoved LICENSE.txt into root. (diff)
downloadopensim-SC_OLD-07d0f558c441a0936441ed23ed076cf54a0dc578.zip
opensim-SC_OLD-07d0f558c441a0936441ed23ed076cf54a0dc578.tar.gz
opensim-SC_OLD-07d0f558c441a0936441ed23ed076cf54a0dc578.tar.bz2
opensim-SC_OLD-07d0f558c441a0936441ed23ed076cf54a0dc578.tar.xz
* Fixed nebadon's UserServer crash bug from yesterday.
* Made Estate tools work for estate managers without needing to request admin status First * Added code to make the Simulator version to be reported in the About box of the client
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/ClientStack/ClientView.cs14
-rw-r--r--OpenSim/Region/Environment/Scenes/Scene.cs23
-rw-r--r--OpenSim/Region/Environment/Scenes/SceneBase.cs5
3 files changed, 40 insertions, 2 deletions
diff --git a/OpenSim/Region/ClientStack/ClientView.cs b/OpenSim/Region/ClientStack/ClientView.cs
index 1717825..d7f4c3d 100644
--- a/OpenSim/Region/ClientStack/ClientView.cs
+++ b/OpenSim/Region/ClientStack/ClientView.cs
@@ -87,7 +87,7 @@ namespace OpenSim.Region.ClientStack
87 private readonly uint m_circuitCode; 87 private readonly uint m_circuitCode;
88 private int m_moneyBalance; 88 private int m_moneyBalance;
89 89
90 private readonly byte[] m_channelVersion = new byte[] { 0x00 }; // Dummy value needed by libSL 90 private byte[] m_channelVersion = Helpers.StringToField("OpenSimulator 0.5"); // Dummy value needed by libSL
91 91
92 /* protected variables */ 92 /* protected variables */
93 93
@@ -196,6 +196,8 @@ namespace OpenSim.Region.ClientStack
196 { 196 {
197 m_moneyBalance = 1000; 197 m_moneyBalance = 1000;
198 198
199 m_channelVersion = Helpers.StringToField(scene.GetSimulatorVersion());
200
199 m_scene = scene; 201 m_scene = scene;
200 m_assetCache = assetCache; 202 m_assetCache = assetCache;
201 203
@@ -609,8 +611,16 @@ namespace OpenSim.Region.ClientStack
609 { 611 {
610 RegionHandshakePacket handshake = (RegionHandshakePacket)PacketPool.Instance.GetPacket(PacketType.RegionHandshake); 612 RegionHandshakePacket handshake = (RegionHandshakePacket)PacketPool.Instance.GetPacket(PacketType.RegionHandshake);
611 613
614 bool estatemanager = false;
615 LLUUID[] EstateManagers = regionInfo.EstateSettings.estateManagers;
616 for (int i = 0; i < EstateManagers.Length; i++)
617 {
618 if (EstateManagers[i] == AgentId)
619 estatemanager = true;
620 }
621
612 handshake.RegionInfo.BillableFactor = regionInfo.EstateSettings.billableFactor; 622 handshake.RegionInfo.BillableFactor = regionInfo.EstateSettings.billableFactor;
613 handshake.RegionInfo.IsEstateManager = false; 623 handshake.RegionInfo.IsEstateManager = estatemanager;
614 handshake.RegionInfo.TerrainHeightRange00 = regionInfo.EstateSettings.terrainHeightRange0; 624 handshake.RegionInfo.TerrainHeightRange00 = regionInfo.EstateSettings.terrainHeightRange0;
615 handshake.RegionInfo.TerrainHeightRange01 = regionInfo.EstateSettings.terrainHeightRange1; 625 handshake.RegionInfo.TerrainHeightRange01 = regionInfo.EstateSettings.terrainHeightRange1;
616 handshake.RegionInfo.TerrainHeightRange10 = regionInfo.EstateSettings.terrainHeightRange2; 626 handshake.RegionInfo.TerrainHeightRange10 = regionInfo.EstateSettings.terrainHeightRange2;
diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs
index 3fafaf4..a4f5028 100644
--- a/OpenSim/Region/Environment/Scenes/Scene.cs
+++ b/OpenSim/Region/Environment/Scenes/Scene.cs
@@ -82,6 +82,8 @@ namespace OpenSim.Region.Environment.Scenes
82 private readonly Timer m_restartTimer = new Timer(15000); // Wait before firing 82 private readonly Timer m_restartTimer = new Timer(15000); // Wait before firing
83 private int m_incrementsof15seconds = 0; 83 private int m_incrementsof15seconds = 0;
84 84
85 public string m_simulatorVersion = "OpenSimulator 0.5";
86
85 protected ModuleLoader m_moduleLoader; 87 protected ModuleLoader m_moduleLoader;
86 protected StorageManager m_storageManager; 88 protected StorageManager m_storageManager;
87 protected AgentCircuitManager m_authenticateHandler; 89 protected AgentCircuitManager m_authenticateHandler;
@@ -300,6 +302,22 @@ namespace OpenSim.Region.Environment.Scenes
300 302
301 m_statsReporter = new SimStatsReporter(regInfo); 303 m_statsReporter = new SimStatsReporter(regInfo);
302 m_statsReporter.OnSendStatsResult += SendSimStatsPackets; 304 m_statsReporter.OnSendStatsResult += SendSimStatsPackets;
305 string OSString = "";
306
307 if (System.Environment.OSVersion.Platform != PlatformID.Unix)
308 {
309 OSString = System.Environment.OSVersion.ToString();
310 }
311 else
312 {
313 OSString = Util.ReadEtcIssue();
314 }
315 if (OSString.Length > 45)
316 {
317 OSString = OSString.Substring(0,45);
318 }
319
320 m_simulatorVersion = "OpenSimulator v0.5-SVN on " + OSString + " ChilTasks:" + m_sendTasksToChild.ToString() + " PhysPrim:" + m_physicalPrim.ToString();
303 } 321 }
304 322
305 #endregion 323 #endregion
@@ -313,6 +331,11 @@ namespace OpenSim.Region.Environment.Scenes
313 m_eventManager.OnPermissionError += SendPermissionAlert; 331 m_eventManager.OnPermissionError += SendPermissionAlert;
314 } 332 }
315 333
334 public override string GetSimulatorVersion()
335 {
336 return m_simulatorVersion;
337 }
338
316 public override bool OtherRegionUp(RegionInfo otherRegion) 339 public override bool OtherRegionUp(RegionInfo otherRegion)
317 { 340 {
318 // Another region is up. 341 // Another region is up.
diff --git a/OpenSim/Region/Environment/Scenes/SceneBase.cs b/OpenSim/Region/Environment/Scenes/SceneBase.cs
index 2e95322..e39fa9f 100644
--- a/OpenSim/Region/Environment/Scenes/SceneBase.cs
+++ b/OpenSim/Region/Environment/Scenes/SceneBase.cs
@@ -167,6 +167,11 @@ namespace OpenSim.Region.Environment.Scenes
167 } 167 }
168 public abstract bool OtherRegionUp(RegionInfo thisRegion); 168 public abstract bool OtherRegionUp(RegionInfo thisRegion);
169 169
170 public virtual string GetSimulatorVersion()
171 {
172 return "OpenSimulator v0.5 SVN";
173 }
174
170 #endregion 175 #endregion
171 176
172 #region Shutdown 177 #region Shutdown