diff options
author | Justin Clarke Casey | 2008-07-03 23:04:12 +0000 |
---|---|---|
committer | Justin Clarke Casey | 2008-07-03 23:04:12 +0000 |
commit | 8251508412940b3f584f051a860a1bb4ddbfb62e (patch) | |
tree | 8a5e460836a8fe6c945e5a3ac4e54445a6d9cfe4 /OpenSim/Region/Environment/Modules/World/Terrain/TerrainModule.cs | |
parent | Mantis#1661. Thank you kindly, CMickeyb for a patch that: (diff) | |
download | opensim-SC_OLD-8251508412940b3f584f051a860a1bb4ddbfb62e.zip opensim-SC_OLD-8251508412940b3f584f051a860a1bb4ddbfb62e.tar.gz opensim-SC_OLD-8251508412940b3f584f051a860a1bb4ddbfb62e.tar.bz2 opensim-SC_OLD-8251508412940b3f584f051a860a1bb4ddbfb62e.tar.xz |
* On client login, send only one terrain patch at a time (with pauses) instead of 4 at a time
* Certain terrains which are fine went patches are sent singly cause a libsecondlife failure when patches are sent in batches
* See http://opensimulator.org/mantis/view.php?id=1662 for more details
Diffstat (limited to 'OpenSim/Region/Environment/Modules/World/Terrain/TerrainModule.cs')
-rw-r--r-- | OpenSim/Region/Environment/Modules/World/Terrain/TerrainModule.cs | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/OpenSim/Region/Environment/Modules/World/Terrain/TerrainModule.cs b/OpenSim/Region/Environment/Modules/World/Terrain/TerrainModule.cs index fb81abc..f47e6c0 100644 --- a/OpenSim/Region/Environment/Modules/World/Terrain/TerrainModule.cs +++ b/OpenSim/Region/Environment/Modules/World/Terrain/TerrainModule.cs | |||
@@ -494,8 +494,9 @@ namespace OpenSim.Region.Environment.Modules.World.Terrain | |||
494 | } | 494 | } |
495 | 495 | ||
496 | /// <summary> | 496 | /// <summary> |
497 | /// Checks to see if the terrain has been modified since last check | 497 | /// Checks to see if the terrain has been modified since last check. |
498 | /// if the call is asked to respect the estate settings for terrain_raise_limit and | 498 | /// If it has been modified, every all the terrain patches are sent to the client. |
499 | /// If the call is asked to respect the estate settings for terrain_raise_limit and | ||
499 | /// terrain_lower_limit, it will clamp terrain updates between these values | 500 | /// terrain_lower_limit, it will clamp terrain updates between these values |
500 | /// currently invoked by client_OnModifyTerrain only and not the Commander interfaces | 501 | /// currently invoked by client_OnModifyTerrain only and not the Commander interfaces |
501 | /// <param name="respectEstateSettings">should height map deltas be limited to the estate settings limits</param> | 502 | /// <param name="respectEstateSettings">should height map deltas be limited to the estate settings limits</param> |
@@ -520,6 +521,7 @@ namespace OpenSim.Region.Environment.Modules.World.Terrain | |||
520 | // what we are going to send to the client | 521 | // what we are going to send to the client |
521 | serialised = m_channel.GetFloatsSerialised(); | 522 | serialised = m_channel.GetFloatsSerialised(); |
522 | } | 523 | } |
524 | |||
523 | SendToClients(serialised, x, y); | 525 | SendToClients(serialised, x, y); |
524 | shouldTaint = true; | 526 | shouldTaint = true; |
525 | } | 527 | } |
@@ -578,7 +580,11 @@ namespace OpenSim.Region.Environment.Modules.World.Terrain | |||
578 | private void SendToClients(float[] serialised, int x, int y) | 580 | private void SendToClients(float[] serialised, int x, int y) |
579 | { | 581 | { |
580 | m_scene.ForEachClient( | 582 | m_scene.ForEachClient( |
581 | delegate(IClientAPI controller) { controller.SendLayerData(x / Constants.TerrainPatchSize, y / Constants.TerrainPatchSize, serialised); }); | 583 | delegate(IClientAPI controller) |
584 | { controller.SendLayerData( | ||
585 | x / Constants.TerrainPatchSize, y / Constants.TerrainPatchSize, serialised); | ||
586 | } | ||
587 | ); | ||
582 | } | 588 | } |
583 | 589 | ||
584 | private void client_OnModifyTerrain(float height, float seconds, byte size, byte action, float north, float west, | 590 | private void client_OnModifyTerrain(float height, float seconds, byte size, byte action, float north, float west, |