From 3fbaef9275dbb1767dc734e2d8dbe1d2cabfb566 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Thu, 22 May 2014 23:52:28 +0100 Subject: If the root prim has a camera-at or camera-eye setting and a sat upon child prim does not, use the root prim offsets. This matches behaviour just tested on the Linden Lab grid. --- OpenSim/Region/Framework/Scenes/ScenePresence.cs | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'OpenSim') diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index ed107e4..026b0b6 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs @@ -2754,8 +2754,15 @@ namespace OpenSim.Region.Framework.Scenes part.AddSittingAvatar(this); cameraAtOffset = part.GetCameraAtOffset(); + + if (cameraAtOffset == Vector3.Zero) + cameraAtOffset = part.ParentGroup.RootPart.GetCameraAtOffset(); + cameraEyeOffset = part.GetCameraEyeOffset(); + if (cameraEyeOffset == Vector3.Zero) + cameraEyeOffset = part.ParentGroup.RootPart.GetCameraEyeOffset(); + if (cameraEyeOffset != Vector3.Zero || cameraAtOffset != Vector3.Zero) cameraEyeOffset += part.OffsetPosition; -- cgit v1.1