diff options
author | Justin Clark-Casey (justincc) | 2014-04-02 01:05:37 +0100 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2014-04-02 01:05:37 +0100 |
commit | 444737c830020970768b75fe97947376f144e1d8 (patch) | |
tree | a96c73160f10e59c979f75307fe0b122e214ad02 /OpenSim/Region | |
parent | minor: disable logging in recently added scene object crossing tests and remo... (diff) | |
download | opensim-SC_OLD-444737c830020970768b75fe97947376f144e1d8.zip opensim-SC_OLD-444737c830020970768b75fe97947376f144e1d8.tar.gz opensim-SC_OLD-444737c830020970768b75fe97947376f144e1d8.tar.bz2 opensim-SC_OLD-444737c830020970768b75fe97947376f144e1d8.tar.xz |
minor: Only calculate fetched usedPrims and simulatorCapacity info in PrimLimitsModule.CanObjectEnter() when we know for sure that we need them.
Diffstat (limited to 'OpenSim/Region')
-rw-r--r-- | OpenSim/Region/OptionalModules/PrimLimitsModule/PrimLimitsModule.cs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/OpenSim/Region/OptionalModules/PrimLimitsModule/PrimLimitsModule.cs b/OpenSim/Region/OptionalModules/PrimLimitsModule/PrimLimitsModule.cs index 18cec6c..b977ad8 100644 --- a/OpenSim/Region/OptionalModules/PrimLimitsModule/PrimLimitsModule.cs +++ b/OpenSim/Region/OptionalModules/PrimLimitsModule/PrimLimitsModule.cs | |||
@@ -131,9 +131,6 @@ namespace OpenSim.Region.OptionalModules | |||
131 | // receiving permissions will perform the check. | 131 | // receiving permissions will perform the check. |
132 | if (newParcel == null) | 132 | if (newParcel == null) |
133 | return true; | 133 | return true; |
134 | |||
135 | int usedPrims = newParcel.PrimCounts.Total; | ||
136 | int simulatorCapacity = newParcel.GetSimulatorMaxPrimCount(); | ||
137 | 134 | ||
138 | // The prim hasn't crossed a region boundry so we don't need to worry | 135 | // The prim hasn't crossed a region boundry so we don't need to worry |
139 | // about prim counts here | 136 | // about prim counts here |
@@ -150,8 +147,11 @@ namespace OpenSim.Region.OptionalModules | |||
150 | } | 147 | } |
151 | 148 | ||
152 | // TODO: Add Special Case here for temporary prims | 149 | // TODO: Add Special Case here for temporary prims |
150 | |||
151 | int usedPrims = newParcel.PrimCounts.Total; | ||
152 | int simulatorCapacity = newParcel.GetSimulatorMaxPrimCount(); | ||
153 | 153 | ||
154 | if(objectCount + usedPrims > simulatorCapacity) | 154 | if (objectCount + usedPrims > simulatorCapacity) |
155 | { | 155 | { |
156 | m_dialogModule.SendAlertToUser(obj.OwnerID, "Unable to move object because the destination parcel is too full"); | 156 | m_dialogModule.SendAlertToUser(obj.OwnerID, "Unable to move object because the destination parcel is too full"); |
157 | return false; | 157 | return false; |