Merge branch 'dev_kitty_debug' into dev_kitty
commit
9ee4a7e9f3
|
@ -978,6 +978,7 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
|
|||
//save script state and stop script instances
|
||||
m_scene.EventManager.TriggerOnSymmetricSyncStop();
|
||||
}
|
||||
m_synced = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -1059,11 +1060,10 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
|
|||
{
|
||||
syncConnector.StartCommThreads();
|
||||
AddSyncConnector(syncConnector);
|
||||
m_synced = true;
|
||||
}
|
||||
}
|
||||
|
||||
m_synced = true;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
@ -2145,8 +2145,11 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
// Make sure no child prim is set for sale
|
||||
// So that, on delink, no prims are unwittingly
|
||||
// left for sale and sold off
|
||||
child.RootPart.ObjectSaleType = 0;
|
||||
child.RootPart.SalePrice = 10;
|
||||
//SYMMETRIC SYNC: need to copy value w/o trigger UpdateBucketSyncInfo
|
||||
//child.RootPart.ObjectSaleType = 0;
|
||||
//child.RootPart.SalePrice = 10;
|
||||
child.RootPart.SetObjectSaleType(0);
|
||||
child.RootPart.SetSalePrice(10);
|
||||
childGroups.Add(child);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -3694,6 +3694,9 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
}
|
||||
|
||||
//Similar actions with DelinkFromGroup, except that m_scene.AddNewSceneObjectBySync is called
|
||||
//!!!!!!!!!!!!!!!!!!NOTE!!!!!!!!!!!!!!!
|
||||
//All SOP properties below is set through calling SetXXX(value) instead of by "XXX=value", as such a value is being changed due to sync (
|
||||
//i.e. triggered by remote operation instead of by local operation
|
||||
public SceneObjectGroup DelinkFromGroupBySync(SceneObjectPart linkPart, bool sendEvents)
|
||||
{
|
||||
// m_log.DebugFormat(
|
||||
|
@ -3714,7 +3717,8 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
if (parts.Length == 1 && RootPart != null)
|
||||
{
|
||||
// Single prim left
|
||||
RootPart.LinkNum = 0;
|
||||
//RootPart.LinkNum = 0;
|
||||
RootPart.SetLinkNum(0);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -3722,13 +3726,18 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
{
|
||||
SceneObjectPart part = parts[i];
|
||||
if (part.LinkNum > linkPart.LinkNum)
|
||||
part.LinkNum--;
|
||||
{
|
||||
//part.LinkNum--;
|
||||
part.SetLinkNum(part.LinkNum--);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
linkPart.ParentID = 0;
|
||||
linkPart.LinkNum = 0;
|
||||
//linkPart.ParentID = 0;
|
||||
//linkPart.LinkNum = 0;
|
||||
linkPart.SetParentID(0);
|
||||
linkPart.SetLinkNum(0);
|
||||
|
||||
if (linkPart.PhysActor != null)
|
||||
{
|
||||
|
@ -3742,11 +3751,15 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
Vector3 axPos = linkPart.OffsetPosition;
|
||||
|
||||
axPos *= parentRot;
|
||||
linkPart.OffsetPosition = new Vector3(axPos.X, axPos.Y, axPos.Z);
|
||||
linkPart.GroupPosition = AbsolutePosition + linkPart.OffsetPosition;
|
||||
linkPart.OffsetPosition = new Vector3(0, 0, 0);
|
||||
//linkPart.OffsetPosition = new Vector3(axPos.X, axPos.Y, axPos.Z);
|
||||
//linkPart.GroupPosition = AbsolutePosition + linkPart.OffsetPosition;
|
||||
//linkPart.OffsetPosition = new Vector3(0, 0, 0);
|
||||
//linkPart.RotationOffset = worldRot;
|
||||
|
||||
linkPart.RotationOffset = worldRot;
|
||||
linkPart.SetOffsetPosition(new Vector3(axPos.X, axPos.Y, axPos.Z));
|
||||
linkPart.SetGroupPosition(AbsolutePosition + linkPart.OffsetPosition);
|
||||
linkPart.SetOffsetPosition(new Vector3(0, 0, 0));
|
||||
linkPart.SetRotationOffset(worldRot);
|
||||
|
||||
SceneObjectGroup objectGroup = new SceneObjectGroup(linkPart);
|
||||
|
||||
|
|
|
@ -608,12 +608,18 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
public uint InventorySerial
|
||||
{
|
||||
get { return m_inventory.Serial; }
|
||||
set { m_inventory.Serial = value; }
|
||||
set
|
||||
{
|
||||
SetInventorySerial(value);
|
||||
UpdateBucketSyncInfo("InventorySerial");
|
||||
//m_inventory.Serial = value;
|
||||
}
|
||||
}
|
||||
//SYMMETRIC SYNC: implemented to be consistent with other properties. "m_inventory.Serial" set function will trigger UpdateBucketSyncInfo if appropriate
|
||||
//SYMMETRIC SYNC: implemented to be consistent with other properties. "m_inventory.Serial" set function will trigger UpdateBucketSyncInfo,
|
||||
//hence in SetInventorySerial we will call m_inventory.SetSerial to avoid triggering UpdateBucketSyncInfo().
|
||||
public void SetInventorySerial(uint value)
|
||||
{
|
||||
m_inventory.Serial = value;
|
||||
m_inventory.SetSerial(value);
|
||||
}
|
||||
|
||||
/// <value>
|
||||
|
@ -622,12 +628,18 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
public TaskInventoryDictionary TaskInventory
|
||||
{
|
||||
get { return m_inventory.Items; }
|
||||
set { m_inventory.Items = value; }
|
||||
set
|
||||
{
|
||||
//SetTaskInventory(value);
|
||||
//UpdateBucketSyncInfo("TaskInventory");
|
||||
//SYMMETRIC SYNC: "m_inventory.Items" set function will trigger UpdateBucketSyncInfo if appropriate
|
||||
m_inventory.Items = value;
|
||||
}
|
||||
}
|
||||
//SYMMETRIC SYNC: implemented to be consistent with other properties. "m_inventory.Items" set function will trigger UpdateBucketSyncInfo if appropriate
|
||||
//SYMMETRIC SYNC: implemented to be consistent with updating values of other properties (w/o triggering UpdateBucketSyncInfo);
|
||||
public void SetTaskInventory(TaskInventoryDictionary value)
|
||||
{
|
||||
m_inventory.Items = value;
|
||||
m_inventory.SetItems(value);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -1227,7 +1239,7 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
set
|
||||
{
|
||||
SetAcceleration(value);
|
||||
UpdateBucketSyncInfo("Acceleration");
|
||||
//UpdateBucketSyncInfo("Acceleration");
|
||||
//m_acceleration = value;
|
||||
}
|
||||
}
|
||||
|
@ -1243,7 +1255,7 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
set
|
||||
{
|
||||
SetDescription(value);
|
||||
UpdateBucketSyncInfo("Description");
|
||||
//UpdateBucketSyncInfo("Description");
|
||||
/*
|
||||
m_description = value;
|
||||
PhysicsActor actor = PhysActor;
|
||||
|
@ -1274,7 +1286,7 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
set
|
||||
{
|
||||
SetColor(value);
|
||||
UpdateBucketSyncInfo("Color");
|
||||
//UpdateBucketSyncInfo("Color");
|
||||
//m_color = value;
|
||||
|
||||
/* ScheduleFullUpdate() need not be called b/c after
|
||||
|
@ -1303,7 +1315,7 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
set
|
||||
{
|
||||
SetText(value, false);
|
||||
UpdateBucketSyncInfo("Text");
|
||||
//UpdateBucketSyncInfo("Text");
|
||||
//m_text = value;
|
||||
}
|
||||
}
|
||||
|
@ -1321,7 +1333,7 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
set
|
||||
{
|
||||
SetSitName(value);
|
||||
UpdateBucketSyncInfo("SitName");
|
||||
//UpdateBucketSyncInfo("SitName");
|
||||
//m_sitName = value;
|
||||
}
|
||||
}
|
||||
|
@ -1369,7 +1381,7 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
set
|
||||
{
|
||||
SetClickAction(value);
|
||||
UpdateBucketSyncInfo("ClickAction");
|
||||
//UpdateBucketSyncInfo("ClickAction");
|
||||
//m_clickAction = value;
|
||||
}
|
||||
}
|
||||
|
@ -1606,6 +1618,11 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
get { return _parentID; }
|
||||
set { _parentID = value; }
|
||||
}
|
||||
//SYMMETRIC SYNC: defined for consistency, for calling SetXXX in sync operations
|
||||
public void SetParentID(uint value)
|
||||
{
|
||||
_parentID = value;
|
||||
}
|
||||
|
||||
public int CreationDate
|
||||
{
|
||||
|
@ -5913,6 +5930,10 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
//private static Dictionary<string, BucketUpdateProcessor> m_bucketUpdateProcessors = new Dictionary<string, BucketUpdateProcessor>();
|
||||
private Dictionary<string, BucketUpdateProcessor> m_bucketUpdateProcessors = new Dictionary<string, BucketUpdateProcessor>();
|
||||
|
||||
//Define this as a guard to not to fill in any sync info when not desired, i.e. while de-serializing and building SOP and SOG, where
|
||||
//property set functions will be called and might trigger UpdateBucketSyncInfo() if not guarded carefully.
|
||||
private bool m_syncEnabled = false;
|
||||
|
||||
public static void InitializeBucketInfo(Dictionary<string, string> propertyBucketMap, List<string> bucketNames, string actorID)
|
||||
{
|
||||
m_primPropertyBucketMap = propertyBucketMap;
|
||||
|
@ -5965,7 +5986,17 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
SetMaterial(updatedPart.Material);
|
||||
SetPassTouches(updatedPart.PassTouches);
|
||||
//RegionHandle skipped
|
||||
SetScriptAccessPin(updatedPart.ScriptAccessPin);
|
||||
|
||||
//SetAcceleration(updatedPart.Acceleration);
|
||||
//SetDescription(updatedPart.Description);
|
||||
//SetColor(updatedPart.Color);
|
||||
//SetText(updatedPart.Text);
|
||||
//SetSitName(updatedPart.SitName);
|
||||
|
||||
SetTouchName(updatedPart.TouchName);
|
||||
SetLinkNum(updatedPart.LinkNum);
|
||||
//SetClickAction(updatedPart.ClickAction);
|
||||
|
||||
SetShape(updatedPart.Shape);
|
||||
|
||||
|
@ -6040,6 +6071,8 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
RegisterBucketUpdateProcessor();
|
||||
m_BucketUpdateProcessorRegistered = true;
|
||||
}
|
||||
|
||||
m_syncEnabled = true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -6048,7 +6081,7 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
/// <param name="propertyName">Name of the property. Make sure the spelling is consistent with what are defined in PropertyList</param>
|
||||
public void UpdateBucketSyncInfo(string propertyName)
|
||||
{
|
||||
if (m_bucketSyncInfoList != null && m_bucketSyncInfoList.Count>0)
|
||||
if (m_syncEnabled && m_bucketSyncInfoList != null && m_bucketSyncInfoList.Count>0)
|
||||
{
|
||||
//int bucketIndex = m_primPropertyBucketMap[propertyName];
|
||||
string bucketName = m_primPropertyBucketMap[propertyName];
|
||||
|
|
|
@ -85,7 +85,7 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
}
|
||||
|
||||
//SYMMETRIC SYNC
|
||||
protected void SetSerial(uint value)
|
||||
public void SetSerial(uint value)
|
||||
{
|
||||
m_inventorySerial = value;
|
||||
|
||||
|
@ -100,6 +100,7 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
set
|
||||
{
|
||||
SetItems(value);
|
||||
m_inventorySerial++;
|
||||
m_part.UpdateBucketSyncInfo("TaskInventory");
|
||||
m_part.UpdateBucketSyncInfo("InventorySerial");
|
||||
//m_items = value;
|
||||
|
@ -107,10 +108,11 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
}
|
||||
}
|
||||
//SYMMETRIC SYNC
|
||||
protected void SetItems(TaskInventoryDictionary value)
|
||||
//This is inparticular for updating properties
|
||||
public void SetItems(TaskInventoryDictionary value)
|
||||
{
|
||||
m_items = value;
|
||||
m_inventorySerial++;
|
||||
//m_inventorySerial++;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
Loading…
Reference in New Issue