Fix issue where llSetCameraAtOffset() and llSetCameraEyeOffset() in non-root prims moved camera/focus to wrong position.

For non-root prim, eye offsets now need to be made relative to root prim if either camera-at or camera-eye are set.
Probably a regression since November 2013 when all sits were made relative to root prim to match viewer expections (and fix other bugs).
Addresses http://opensimulator.org/mantis/view.php?id=7176
bullet-2.82
Justin Clark-Casey (justincc) 2014-05-22 23:39:22 +01:00
parent f8b8241239
commit 16bf38e1ab
1 changed files with 4 additions and 0 deletions

View File

@ -2755,6 +2755,10 @@ namespace OpenSim.Region.Framework.Scenes
cameraAtOffset = part.GetCameraAtOffset(); cameraAtOffset = part.GetCameraAtOffset();
cameraEyeOffset = part.GetCameraEyeOffset(); cameraEyeOffset = part.GetCameraEyeOffset();
if (cameraEyeOffset != Vector3.Zero || cameraAtOffset != Vector3.Zero)
cameraEyeOffset += part.OffsetPosition;
forceMouselook = part.GetForceMouselook(); forceMouselook = part.GetForceMouselook();
// An viewer expects to specify sit positions as offsets to the root prim, even if a child prim is // An viewer expects to specify sit positions as offsets to the root prim, even if a child prim is