mirror of
https://github.com/opensim/opensim.git
synced 2026-08-01 14:16:07 +08:00
Fix problem where moving an object to another region on the same simulator was failing, with the object returning to its original position.
Root cause was that PrimLimitsModule was not properly handling the case where the parcel it was asked to check was outside the current region's bounds. If this is the case, we can abort the check since the receiving region will perform it. Added a regression test for this case.
This commit is contained in:
@@ -58,8 +58,6 @@ namespace OpenSim.Region.OptionalModules
|
||||
|
||||
public void Initialise(IConfigSource config)
|
||||
{
|
||||
//IConfig myConfig = config.Configs["Startup"];
|
||||
|
||||
string permissionModules = Util.GetConfigVarFromSections<string>(config, "permissionmodules",
|
||||
new string[] { "Startup", "Permissions" }, "DefaultPermissionsModule");
|
||||
|
||||
@@ -129,6 +127,11 @@ namespace OpenSim.Region.OptionalModules
|
||||
ILandObject oldParcel = scene.LandChannel.GetLandObject(oldPoint.X, oldPoint.Y);
|
||||
ILandObject newParcel = scene.LandChannel.GetLandObject(newPoint.X, newPoint.Y);
|
||||
|
||||
// newParcel will be null only if it outside of our current region. If this is the case, then the
|
||||
// receiving permissions will perform the check.
|
||||
if (newParcel == null)
|
||||
return true;
|
||||
|
||||
int usedPrims = newParcel.PrimCounts.Total;
|
||||
int simulatorCapacity = newParcel.GetSimulatorMaxPrimCount();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user