diff options
author | Teravus Ovares (Dan Olivares) | 2009-08-07 20:31:48 -0400 |
---|---|---|
committer | Teravus Ovares (Dan Olivares) | 2009-08-07 20:31:48 -0400 |
commit | 2b990a61bfa88e13d5ad19602e6acef751ea473c (patch) | |
tree | d7cf9705923c940646e2db3af67bdb98944d9392 /OpenSim/Region/OptionalModules | |
parent | * Remove hard coded 256 limitations from various places. There's no more 2... (diff) | |
download | opensim-SC_OLD-2b990a61bfa88e13d5ad19602e6acef751ea473c.zip opensim-SC_OLD-2b990a61bfa88e13d5ad19602e6acef751ea473c.tar.gz opensim-SC_OLD-2b990a61bfa88e13d5ad19602e6acef751ea473c.tar.bz2 opensim-SC_OLD-2b990a61bfa88e13d5ad19602e6acef751ea473c.tar.xz |
This is the second part of the 'not crash on regionsize changes'. This lets you configure region sizes to be smaller without crashing the region. I remind you that regions are still square, must be a multiple of 4, and the Linden client doesn't like anything other then 256. If you set it bigger or smaller, the terrain doesn't load in the client, the map has issues, and god forbid you connect it to a grid that expects 256m regions.
Diffstat (limited to 'OpenSim/Region/OptionalModules')
5 files changed, 7 insertions, 7 deletions
diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs index 44bd716..08fc61f 100644 --- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs +++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs | |||
@@ -513,7 +513,7 @@ namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server | |||
513 | 513 | ||
514 | public Vector3 StartPos | 514 | public Vector3 StartPos |
515 | { | 515 | { |
516 | get { return new Vector3(128, 128, 50); } | 516 | get { return new Vector3(((int)Constants.RegionSize * 0.5f), ((int)Constants.RegionSize * 0.5f), 50); } |
517 | set { } | 517 | set { } |
518 | } | 518 | } |
519 | 519 | ||
diff --git a/OpenSim/Region/OptionalModules/Avatar/Chat/IRCConnector.cs b/OpenSim/Region/OptionalModules/Avatar/Chat/IRCConnector.cs index 2f1dbc1..9273fb5 100644 --- a/OpenSim/Region/OptionalModules/Avatar/Chat/IRCConnector.cs +++ b/OpenSim/Region/OptionalModules/Avatar/Chat/IRCConnector.cs | |||
@@ -50,8 +50,8 @@ namespace OpenSim.Region.OptionalModules.Avatar.Chat | |||
50 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 50 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
51 | 51 | ||
52 | // Local constants | 52 | // Local constants |
53 | 53 | ||
54 | private static readonly Vector3 CenterOfRegion = new Vector3(128, 128, 20); | 54 | private static readonly Vector3 CenterOfRegion = new Vector3(((int)Constants.RegionSize * 0.5f), ((int)Constants.RegionSize * 0.5f), 20); |
55 | private static readonly char[] CS_SPACE = { ' ' }; | 55 | private static readonly char[] CS_SPACE = { ' ' }; |
56 | 56 | ||
57 | private const int WD_INTERVAL = 1000; // base watchdog interval | 57 | private const int WD_INTERVAL = 1000; // base watchdog interval |
diff --git a/OpenSim/Region/OptionalModules/Avatar/Chat/RegionState.cs b/OpenSim/Region/OptionalModules/Avatar/Chat/RegionState.cs index ba3f3e5..203948e 100644 --- a/OpenSim/Region/OptionalModules/Avatar/Chat/RegionState.cs +++ b/OpenSim/Region/OptionalModules/Avatar/Chat/RegionState.cs | |||
@@ -45,7 +45,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.Chat | |||
45 | private static readonly ILog m_log = | 45 | private static readonly ILog m_log = |
46 | LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 46 | LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
47 | 47 | ||
48 | private static readonly OpenMetaverse.Vector3 CenterOfRegion = new OpenMetaverse.Vector3(128, 128, 20); | 48 | private static readonly OpenMetaverse.Vector3 CenterOfRegion = new OpenMetaverse.Vector3(((int)Constants.RegionSize * 0.5f), ((int)Constants.RegionSize * 0.5f), 20); |
49 | private const int DEBUG_CHANNEL = 2147483647; | 49 | private const int DEBUG_CHANNEL = 2147483647; |
50 | 50 | ||
51 | private static int _idk_ = 0; | 51 | private static int _idk_ = 0; |
diff --git a/OpenSim/Region/OptionalModules/Scripting/RegionReady/RegionReady.cs b/OpenSim/Region/OptionalModules/Scripting/RegionReady/RegionReady.cs index d3f3e10..f2c6db1 100644 --- a/OpenSim/Region/OptionalModules/Scripting/RegionReady/RegionReady.cs +++ b/OpenSim/Region/OptionalModules/Scripting/RegionReady/RegionReady.cs | |||
@@ -125,7 +125,7 @@ namespace OpenSim.Region.CoreModules.Scripting.RegionReady | |||
125 | c.Channel = m_channelNotify; | 125 | c.Channel = m_channelNotify; |
126 | c.Message += numScriptsFailed.ToString() + "," + message; | 126 | c.Message += numScriptsFailed.ToString() + "," + message; |
127 | c.Type = ChatTypeEnum.Region; | 127 | c.Type = ChatTypeEnum.Region; |
128 | c.Position = new Vector3(128, 128, 30); | 128 | c.Position = new Vector3(((int)Constants.RegionSize * 0.5f), ((int)Constants.RegionSize * 0.5f), 30); |
129 | c.Sender = null; | 129 | c.Sender = null; |
130 | c.SenderUUID = UUID.Zero; | 130 | c.SenderUUID = UUID.Zero; |
131 | 131 | ||
diff --git a/OpenSim/Region/OptionalModules/World/TreePopulator/TreePopulatorModule.cs b/OpenSim/Region/OptionalModules/World/TreePopulator/TreePopulatorModule.cs index 3e9c326..d4bba10 100644 --- a/OpenSim/Region/OptionalModules/World/TreePopulator/TreePopulatorModule.cs +++ b/OpenSim/Region/OptionalModules/World/TreePopulator/TreePopulatorModule.cs | |||
@@ -755,8 +755,8 @@ namespace OpenSim.Region.OptionalModules.World.TreePopulator | |||
755 | position.X = s_tree.AbsolutePosition.X + (float)randX; | 755 | position.X = s_tree.AbsolutePosition.X + (float)randX; |
756 | position.Y = s_tree.AbsolutePosition.Y + (float)randY; | 756 | position.Y = s_tree.AbsolutePosition.Y + (float)randY; |
757 | 757 | ||
758 | if (position.X <= 255 && position.X >= 0 && | 758 | if (position.X <= ((int)Constants.RegionSize - 1) && position.X >= 0 && |
759 | position.Y <= 255 && position.Y >= 0 && | 759 | position.Y <= ((int)Constants.RegionSize - 1) && position.Y >= 0 && |
760 | Util.GetDistanceTo(position, copse.m_seed_point) <= copse.m_range) | 760 | Util.GetDistanceTo(position, copse.m_seed_point) <= copse.m_range) |
761 | { | 761 | { |
762 | UUID uuid = m_scene.RegionInfo.EstateSettings.EstateOwner; | 762 | UUID uuid = m_scene.RegionInfo.EstateSettings.EstateOwner; |