diff options
Diffstat (limited to 'OpenSim/Region')
-rw-r--r-- | OpenSim/Region/CoreModules/World/Land/LandObject.cs | 25 | ||||
-rw-r--r-- | OpenSim/Region/OptionalModules/PrimLimitsModule/PrimLimitsModule.cs | 4 |
2 files changed, 20 insertions, 9 deletions
diff --git a/OpenSim/Region/CoreModules/World/Land/LandObject.cs b/OpenSim/Region/CoreModules/World/Land/LandObject.cs index 69a3455..4cbc8b8 100644 --- a/OpenSim/Region/CoreModules/World/Land/LandObject.cs +++ b/OpenSim/Region/CoreModules/World/Land/LandObject.cs | |||
@@ -341,10 +341,16 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
341 | else | 341 | else |
342 | { | 342 | { |
343 | // Normal Calculations | 343 | // Normal Calculations |
344 | int parcelMax = (int)( (long)LandData.Area | 344 | int parcelMax = (int)( |
345 | * (long)m_scene.RegionInfo.ObjectCapacity | 345 | (double)LandData.Area |
346 | * (long)m_scene.RegionInfo.RegionSettings.ObjectBonus | 346 | * (double)m_scene.RegionInfo.ObjectCapacity |
347 | / (long)(m_scene.RegionInfo.RegionSizeX * m_scene.RegionInfo.RegionSizeY) ); | 347 | * (double)m_scene.RegionInfo.RegionSettings.ObjectBonus |
348 | / (double)(m_scene.RegionInfo.RegionSizeX * m_scene.RegionInfo.RegionSizeY) | ||
349 | + 0.5 ); | ||
350 | |||
351 | if(parcelMax > m_scene.RegionInfo.ObjectCapacity) | ||
352 | parcelMax = m_scene.RegionInfo.ObjectCapacity; | ||
353 | |||
348 | //m_log.DebugFormat("Area: {0}, Capacity {1}, Bonus {2}, Parcel {3}", LandData.Area, m_scene.RegionInfo.ObjectCapacity, m_scene.RegionInfo.RegionSettings.ObjectBonus, parcelMax); | 354 | //m_log.DebugFormat("Area: {0}, Capacity {1}, Bonus {2}, Parcel {3}", LandData.Area, m_scene.RegionInfo.ObjectCapacity, m_scene.RegionInfo.RegionSettings.ObjectBonus, parcelMax); |
349 | return parcelMax; | 355 | return parcelMax; |
350 | } | 356 | } |
@@ -359,9 +365,14 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
359 | else | 365 | else |
360 | { | 366 | { |
361 | //Normal Calculations | 367 | //Normal Calculations |
362 | int simMax = (int)( (long)LandData.SimwideArea | 368 | int simMax = (int)( (double)LandData.SimwideArea |
363 | * (long)m_scene.RegionInfo.ObjectCapacity | 369 | * (double)m_scene.RegionInfo.ObjectCapacity |
364 | / (long)(m_scene.RegionInfo.RegionSizeX * m_scene.RegionInfo.RegionSizeY) ); | 370 | * (double)m_scene.RegionInfo.RegionSettings.ObjectBonus |
371 | / (long)(m_scene.RegionInfo.RegionSizeX * m_scene.RegionInfo.RegionSizeY) | ||
372 | +0.5 ); | ||
373 | |||
374 | if(simMax > m_scene.RegionInfo.ObjectCapacity) | ||
375 | simMax = m_scene.RegionInfo.ObjectCapacity; | ||
365 | //m_log.DebugFormat("Simwide Area: {0}, Capacity {1}, SimMax {2}, SimWidePrims {3}", | 376 | //m_log.DebugFormat("Simwide Area: {0}, Capacity {1}, SimMax {2}, SimWidePrims {3}", |
366 | // LandData.SimwideArea, m_scene.RegionInfo.ObjectCapacity, simMax, LandData.SimwidePrims); | 377 | // LandData.SimwideArea, m_scene.RegionInfo.ObjectCapacity, simMax, LandData.SimwidePrims); |
367 | return simMax; | 378 | return simMax; |
diff --git a/OpenSim/Region/OptionalModules/PrimLimitsModule/PrimLimitsModule.cs b/OpenSim/Region/OptionalModules/PrimLimitsModule/PrimLimitsModule.cs index 50a5fae..4ffb03b 100644 --- a/OpenSim/Region/OptionalModules/PrimLimitsModule/PrimLimitsModule.cs +++ b/OpenSim/Region/OptionalModules/PrimLimitsModule/PrimLimitsModule.cs | |||
@@ -186,8 +186,8 @@ namespace OpenSim.Region.OptionalModules | |||
186 | { | 186 | { |
187 | string response = null; | 187 | string response = null; |
188 | 188 | ||
189 | int simulatorCapacity = lo.GetSimulatorMaxPrimCount(); | 189 | int OwnedParcelsCapacity = lo.GetSimulatorMaxPrimCount(); |
190 | if ((objectCount + lo.PrimCounts.Total) > simulatorCapacity) | 190 | if ((objectCount + lo.PrimCounts.Total) > OwnedParcelsCapacity) |
191 | { | 191 | { |
192 | response = "Unable to rez object because the parcel is too full"; | 192 | response = "Unable to rez object because the parcel is too full"; |
193 | } | 193 | } |