diff options
author | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2022-05-20 23:19:26 +0300 |
---|---|---|
committer | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2022-05-20 23:19:26 +0300 |
commit | 397f401a5058732a5947e2676815999cf004c5eb (patch) | |
tree | 8880dbb47c03782989d6e662f06504c454526a41 /indra/newview/llpanelobject.cpp | |
parent | d1265cda36f31d0273b0cd57e1e6c762dfc0b29f (diff) |
SL-17436 Tools floater drops negative Z position for attachments
Diffstat (limited to 'indra/newview/llpanelobject.cpp')
-rw-r--r-- | indra/newview/llpanelobject.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/indra/newview/llpanelobject.cpp b/indra/newview/llpanelobject.cpp index 831c89b005..a6d704a7c5 100644 --- a/indra/newview/llpanelobject.cpp +++ b/indra/newview/llpanelobject.cpp @@ -1644,13 +1644,13 @@ void LLPanelObject::sendPosition(BOOL btn_down) LLVector3 newpos(mCtrlPosX->get(), mCtrlPosY->get(), mCtrlPosZ->get()); LLViewerRegion* regionp = mObject->getRegion(); - // Clamp the Z height - const F32 height = newpos.mV[VZ]; - const F32 min_height = LLWorld::getInstance()->getMinAllowedZ(mObject, mObject->getPositionGlobal()); - const F32 max_height = LLWorld::getInstance()->getRegionMaxHeight(); - if (!mObject->isAttachment()) { + // Clamp the Z height + const F32 height = newpos.mV[VZ]; + const F32 min_height = LLWorld::getInstance()->getMinAllowedZ(mObject, mObject->getPositionGlobal()); + const F32 max_height = LLWorld::getInstance()->getRegionMaxHeight(); + if ( height < min_height) { newpos.mV[VZ] = min_height; |