Fix the ability to move the seated avatar via LSL

avinationmerge
Melanie 2011-11-08 23:15:09 +01:00
parent adbc69bb07
commit d40d0e4596
1 changed files with 3 additions and 0 deletions

View File

@ -1914,6 +1914,7 @@ namespace OpenSim.Region.Framework.Scenes
if (part.SitTargetAvatar == UUID) if (part.SitTargetAvatar == UUID)
part.SitTargetAvatar = UUID.Zero; part.SitTargetAvatar = UUID.Zero;
part.ParentGroup.DeleteAvatar(UUID);
ParentPosition = part.GetWorldPosition(); ParentPosition = part.GetWorldPosition();
ControllingClient.SendClearFollowCamProperties(part.ParentUUID); ControllingClient.SendClearFollowCamProperties(part.ParentUUID);
} }
@ -2343,11 +2344,13 @@ namespace OpenSim.Region.Framework.Scenes
m_pos = sitTargetPos + SIT_TARGET_ADJUSTMENT; m_pos = sitTargetPos + SIT_TARGET_ADJUSTMENT;
Rotation = sitTargetOrient; Rotation = sitTargetOrient;
ParentPosition = part.AbsolutePosition; ParentPosition = part.AbsolutePosition;
part.ParentGroup.AddAvatar(UUID);
} }
else else
{ {
m_pos -= part.AbsolutePosition; m_pos -= part.AbsolutePosition;
ParentPosition = part.AbsolutePosition; ParentPosition = part.AbsolutePosition;
part.ParentGroup.AddAvatar(UUID);
// m_log.DebugFormat( // m_log.DebugFormat(
// "[SCENE PRESENCE]: Sitting {0} at position {1} ({2} + {3}) on part {4} {5} without sit target", // "[SCENE PRESENCE]: Sitting {0} at position {1} ({2} + {3}) on part {4} {5} without sit target",