diff options
Make sure the avatar position gets moved along with a prim it is sitting on. This fixes mantis #208 and (maybe) issues with chat and sound coming from the wrong place when sat on a vehicle.
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/ScenePresence.cs')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/ScenePresence.cs | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 5fcd1c2..44c3d12 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs | |||
@@ -595,11 +595,21 @@ namespace OpenSim.Region.Framework.Scenes | |||
595 | 595 | ||
596 | private uint m_parentID; | 596 | private uint m_parentID; |
597 | 597 | ||
598 | |||
599 | private UUID m_linkedPrim; | ||
600 | |||
598 | public uint ParentID | 601 | public uint ParentID |
599 | { | 602 | { |
600 | get { return m_parentID; } | 603 | get { return m_parentID; } |
601 | set { m_parentID = value; } | 604 | set { m_parentID = value; } |
602 | } | 605 | } |
606 | |||
607 | public UUID LinkedPrim | ||
608 | { | ||
609 | get { return m_linkedPrim; } | ||
610 | set { m_linkedPrim = value; } | ||
611 | } | ||
612 | |||
603 | public float Health | 613 | public float Health |
604 | { | 614 | { |
605 | get { return m_health; } | 615 | get { return m_health; } |
@@ -1835,6 +1845,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
1835 | 1845 | ||
1836 | m_parentPosition = Vector3.Zero; | 1846 | m_parentPosition = Vector3.Zero; |
1837 | m_parentID = 0; | 1847 | m_parentID = 0; |
1848 | m_linkedPrim = UUID.Zero; | ||
1838 | m_offsetRotation = new Quaternion(0.0f, 0.0f, 0.0f, 1.0f); | 1849 | m_offsetRotation = new Quaternion(0.0f, 0.0f, 0.0f, 1.0f); |
1839 | SendFullUpdateToAllClients(); | 1850 | SendFullUpdateToAllClients(); |
1840 | m_requestedSitTargetID = 0; | 1851 | m_requestedSitTargetID = 0; |
@@ -2422,6 +2433,8 @@ Console.WriteLine("Scripted Sit ofset {0}", m_pos); | |||
2422 | m_parentID = m_requestedSitTargetID; | 2433 | m_parentID = m_requestedSitTargetID; |
2423 | } | 2434 | } |
2424 | 2435 | ||
2436 | m_linkedPrim = part.UUID; | ||
2437 | |||
2425 | Velocity = Vector3.Zero; | 2438 | Velocity = Vector3.Zero; |
2426 | RemoveFromPhysicalScene(); | 2439 | RemoveFromPhysicalScene(); |
2427 | 2440 | ||