mirror of
https://github.com/opensim/opensim.git
synced 2026-08-01 06:06:06 +08:00
Allow Linden trees to preserve their type when taken into inventory and rezzed again. Allow Linden trees to be sensed by LLSensor as PASSIVE objects.
This commit is contained in:
@@ -387,7 +387,12 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
|
||||
inventoryStoredPosition = objectGroup.RootPart.AttachOffset;
|
||||
inventoryStoredRotation = objectGroup.RootPart.AttachRotation;
|
||||
}
|
||||
objectGroup.RootPart.Shape.State = objectGroup.RootPart.AttachPoint;
|
||||
|
||||
// Trees could be attached and it's been done, but it makes
|
||||
// no sense. State must be preserved because it's the tree type
|
||||
if (objectGroup.RootPart.Shape.PCode != (byte)PCode.Tree &&
|
||||
objectGroup.RootPart.Shape.PCode != (byte)PCode.NewTree)
|
||||
objectGroup.RootPart.Shape.State = objectGroup.RootPart.AttachPoint;
|
||||
|
||||
objectGroup.AbsolutePosition = inventoryStoredPosition;
|
||||
objectGroup.RootPart.RotationOffset = inventoryStoredRotation;
|
||||
@@ -791,7 +796,9 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
|
||||
g.RootPart.AttachPoint = g.RootPart.Shape.State;
|
||||
g.RootPart.AttachOffset = g.AbsolutePosition;
|
||||
g.RootPart.AttachRotation = g.GroupRotation;
|
||||
g.RootPart.Shape.State = 0;
|
||||
if (g.RootPart.Shape.PCode != (byte)PCode.NewTree &&
|
||||
g.RootPart.Shape.PCode != (byte)PCode.Tree)
|
||||
g.RootPart.Shape.State = 0;
|
||||
}
|
||||
|
||||
objlist.Add(g);
|
||||
@@ -825,7 +832,9 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
|
||||
g.RootPart.AttachPoint = g.RootPart.Shape.State;
|
||||
g.RootPart.AttachOffset = g.AbsolutePosition;
|
||||
g.RootPart.AttachRotation = g.GroupRotation;
|
||||
g.RootPart.Shape.State = 0;
|
||||
if (g.RootPart.Shape.PCode != (byte)PCode.NewTree &&
|
||||
g.RootPart.Shape.PCode != (byte)PCode.Tree)
|
||||
g.RootPart.Shape.State = 0;
|
||||
|
||||
objlist.Add(g);
|
||||
XmlElement el = (XmlElement)n;
|
||||
|
||||
Reference in New Issue
Block a user