Merge branch 'master' into careminster-presence-refactor
commit
ccf63a9c63
|
@ -75,6 +75,9 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
|
|||
if (name == Name)
|
||||
{
|
||||
m_Enabled = true;
|
||||
|
||||
InitialiseCommon(source);
|
||||
|
||||
m_log.InfoFormat("[HG INVENTORY ACCESS MODULE]: {0} enabled.", Name);
|
||||
|
||||
IConfig thisModuleConfig = source.Configs["HGInventoryAccessModule"];
|
||||
|
|
|
@ -65,6 +65,7 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
|
|||
}
|
||||
}
|
||||
|
||||
public bool CoalesceMultipleObjectsToInventory { get; set; }
|
||||
|
||||
#region INonSharedRegionModule
|
||||
|
||||
|
@ -87,11 +88,29 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
|
|||
if (name == Name)
|
||||
{
|
||||
m_Enabled = true;
|
||||
|
||||
InitialiseCommon(source);
|
||||
|
||||
m_log.InfoFormat("[INVENTORY ACCESS MODULE]: {0} enabled.", Name);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Common module config for both this and descendant classes.
|
||||
/// </summary>
|
||||
/// <param name="source"></param>
|
||||
protected virtual void InitialiseCommon(IConfigSource source)
|
||||
{
|
||||
IConfig inventoryConfig = source.Configs["Inventory"];
|
||||
|
||||
if (inventoryConfig != null)
|
||||
CoalesceMultipleObjectsToInventory
|
||||
= inventoryConfig.GetBoolean("CoalesceMultipleObjectsToInventory", true);
|
||||
else
|
||||
CoalesceMultipleObjectsToInventory = true;
|
||||
}
|
||||
|
||||
public virtual void PostInitialise()
|
||||
{
|
||||
}
|
||||
|
@ -206,14 +225,13 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
|
|||
public virtual UUID DeleteToInventory(DeRezAction action, UUID folderID,
|
||||
List<SceneObjectGroup> objectGroups, IClientAPI remoteClient)
|
||||
{
|
||||
UUID ret = UUID.Zero;
|
||||
Dictionary<UUID, List<SceneObjectGroup>> deletes = new Dictionary<UUID, List<SceneObjectGroup>>();
|
||||
|
||||
if (CoalesceMultipleObjectsToInventory)
|
||||
{
|
||||
// The following code groups the SOG's by owner. No objects
|
||||
// belonging to different people can be coalesced, for obvious
|
||||
// reasons.
|
||||
Dictionary<UUID, List<SceneObjectGroup>> deletes =
|
||||
new Dictionary<UUID, List<SceneObjectGroup>>();
|
||||
|
||||
foreach (SceneObjectGroup g in objectGroups)
|
||||
{
|
||||
if (!deletes.ContainsKey(g.OwnerID))
|
||||
|
@ -221,6 +239,17 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
|
|||
|
||||
deletes[g.OwnerID].Add(g);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// If we don't want to coalesce then put every object in its own bundle.
|
||||
foreach (SceneObjectGroup g in objectGroups)
|
||||
{
|
||||
List<SceneObjectGroup> bundle = new List<SceneObjectGroup>();
|
||||
bundle.Add(g);
|
||||
deletes[g.UUID] = bundle;
|
||||
}
|
||||
}
|
||||
|
||||
// This is pethod scoped and will be returned. It will be the
|
||||
// last created asset id
|
||||
|
@ -240,9 +269,9 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
|
|||
? 250
|
||||
: objectGroup.AbsolutePosition.X)
|
||||
,
|
||||
(objectGroup.AbsolutePosition.X > (int)Constants.RegionSize)
|
||||
(objectGroup.AbsolutePosition.Y > (int)Constants.RegionSize)
|
||||
? 250
|
||||
: objectGroup.AbsolutePosition.X,
|
||||
: objectGroup.AbsolutePosition.Y,
|
||||
objectGroup.AbsolutePosition.Z);
|
||||
|
||||
Vector3 originalPosition = objectGroup.AbsolutePosition;
|
||||
|
|
|
@ -453,6 +453,13 @@
|
|||
; ForwardOfflineGroupMessages = true
|
||||
|
||||
|
||||
[Inventory]
|
||||
; Control whether multiple objects sent to inventory should be coaleseced into a single item
|
||||
; There are still some issues with coalescence, including the fact that rotation is not restored
|
||||
; and some assets may be missing from archive files.
|
||||
CoalesceMultipleObjectsToInventory = true
|
||||
|
||||
|
||||
[ODEPhysicsSettings]
|
||||
;##
|
||||
;## World Settings
|
||||
|
|
Loading…
Reference in New Issue