diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml
index 50d42d8ff..dc3243222 100644
--- a/indra/newview/app_settings/settings.xml
+++ b/indra/newview/app_settings/settings.xml
@@ -37,36 +37,36 @@
AscentBuildAlwaysEnabled
AscentDisableMinZoomDist
AscentFlyAlwaysEnabled
AscentDisplayTotalScriptJumps
- Ascentnumscripts
-
AscentBuildPrefs_ActualRoot
Comment
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp
index fa88cdb39..0054f37b2 100644
--- a/indra/newview/llagent.cpp
+++ b/indra/newview/llagent.cpp
@@ -1971,7 +1971,7 @@ void LLAgent::cameraOrbitIn(const F32 meters)
mCameraZoomFraction = (mTargetCameraDistance - meters) / camera_offset_dist;
- if (!gSavedSettings.getBOOL("FreezeTime") && mCameraZoomFraction < MIN_ZOOM_FRACTION && meters > 0.f)
+ if (!LLAppViewer::sFreezeTime && mCameraZoomFraction < MIN_ZOOM_FRACTION && meters > 0.f)
{
// No need to animate, camera is already there.
changeCameraToMouselook(FALSE);
@@ -1985,13 +1985,48 @@ void LLAgent::cameraOrbitIn(const F32 meters)
LLVector3d camera_offset_unit(mCameraFocusOffsetTarget);
F32 current_distance = (F32)camera_offset_unit.normalize();
F32 new_distance = current_distance - meters;
+ /*
+ F32 min_zoom = LAND_MIN_ZOOM;
+
+ // Don't move through focus point
+ if (mFocusObject.notNull())
+ {
+ if (mFocusObject->isAvatar())
+ {
+ min_zoom = AVATAR_MIN_ZOOM;
+ }
+ else
+ {
+ min_zoom = OBJECT_MIN_ZOOM;
+ }
+ }
+ new_distance = llmax(new_distance, min_zoom);
+
+ // Don't zoom too far back
+ const F32 DIST_FUDGE = 16.f; // meters
+ F32 max_distance = llmin(mDrawDistance - DIST_FUDGE,
+ LLWorld::getInstance()->getRegionWidthInMeters() - DIST_FUDGE );
+
+ if (new_distance > max_distance)
+ {
+ // Unless camera is unlocked
+ if (!gSavedSettings.getBOOL("DisableCameraConstraints"))
+ {
+ return;
+ }
+ }
+
+ if( CAMERA_MODE_CUSTOMIZE_AVATAR == getCameraMode() )
+ {
+ new_distance = llclamp( new_distance, APPEARANCE_MIN_ZOOM, APPEARANCE_MAX_ZOOM );
+ }
+ */
+ // Compute new camera offset
mCameraFocusOffsetTarget = new_distance * camera_offset_unit;
cameraZoomIn(1.f);
}
}
-
-
//-----------------------------------------------------------------------------
// cameraPanIn()
//-----------------------------------------------------------------------------
@@ -3876,55 +3911,6 @@ LLVector3d LLAgent::calcCameraPositionTargetGlobal(BOOL *hit_limit)
camera_position_global = focusPosGlobal + mCameraFocusOffset;
}
- if (!gSavedSettings.getBOOL("DisableCameraConstraints") && !gAgent.isGodlike())
- {
- LLViewerRegion* regionp = LLWorld::getInstance()->getRegionFromPosGlobal(
- camera_position_global);
- bool constrain = true;
- if(regionp && regionp->canManageEstate())
- {
- constrain = false;
- }
- if(constrain)
- {
- F32 max_dist = ( CAMERA_MODE_CUSTOMIZE_AVATAR == mCameraMode ) ?
- APPEARANCE_MAX_ZOOM : mDrawDistance;
-
- LLVector3d camera_offset = camera_position_global
- - gAgent.getPositionGlobal();
- F32 camera_distance = (F32)camera_offset.magVec();
-
- if(camera_distance > max_dist)
- {
- camera_position_global = gAgent.getPositionGlobal() +
- (max_dist / camera_distance) * camera_offset;
- isConstrained = TRUE;
- }
- }
-
-// JC - Could constrain camera based on parcel stuff here.
-// LLViewerRegion *regionp = LLWorld::getInstance()->getRegionFromPosGlobal(camera_position_global);
-//
-// if (regionp && !regionp->mParcelOverlay->isBuildCameraAllowed(regionp->getPosRegionFromGlobal(camera_position_global)))
-// {
-// camera_position_global = last_position_global;
-//
-// isConstrained = TRUE;
-// }
- }
-
- // Don't let camera go underground
- F32 camera_min_off_ground = getCameraMinOffGround();
-
- camera_land_height = LLWorld::getInstance()->resolveLandHeightGlobal(camera_position_global);
-
- if (camera_position_global.mdV[VZ] < camera_land_height + camera_min_off_ground)
- {
- camera_position_global.mdV[VZ] = camera_land_height + camera_min_off_ground;
- isConstrained = TRUE;
- }
-
-
if (hit_limit)
{
*hit_limit = isConstrained;
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index 8cdbb9ef6..4dd61121f 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -3440,53 +3440,50 @@ void handle_close_all_notifications(void*)
// The following animations were made by Charley Levenque and are
// not public property or free to use via UUID. When replicating
// this code, please supply your own animations.
+
+void set_current_pose(std::string anim)
+{
+ if (current_pose == LLUUID::null)
+ gSavedSettings.setF32("AscentAvatarZModifier", gSavedSettings.getF32("AscentAvatarZModifier") + 7.5);
+
+ gAgent.sendAgentSetAppearance();
+ gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_STOP);
+ current_pose.set(anim);
+ gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_START);
+}
void handle_pose_stand_ltao(void*)
{
- gSavedSettings.setF32("AscentAvatarZModifier", 5.0);
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_STOP);
- current_pose.set("6c082c7b-f70e-9da0-0451-54793f869ff4");
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_START);
+ set_current_pose("6c082c7b-f70e-9da0-0451-54793f869ff4");
}
void handle_pose_stand_ltah(void*)
{
- gSavedSettings.setF32("AscentAvatarZModifier", 5.0);
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_STOP);
- current_pose.set("45e59c14-913b-c58c-2a55-c0a5c1eeef53");
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_START);
+ set_current_pose("45e59c14-913b-c58c-2a55-c0a5c1eeef53");
}
void handle_pose_stand_ltad(void*)
{
- gSavedSettings.setF32("AscentAvatarZModifier", 5.0);
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_STOP);
- current_pose.set("421d6bb4-94a9-3c42-4593-f2bc1f6a26e6");
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_START);
+ set_current_pose("421d6bb4-94a9-3c42-4593-f2bc1f6a26e6");
}
void handle_pose_stand_loau(void*)
{
- gSavedSettings.setF32("AscentAvatarZModifier", 5.0);
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_STOP);
- current_pose.set("8b3bb239-d610-1c0f-4d1a-69d29bc17e2c");
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_START);
+ set_current_pose("8b3bb239-d610-1c0f-4d1a-69d29bc17e2c");
}
void handle_pose_stand_loao(void*)
{
- gSavedSettings.setF32("AscentAvatarZModifier", 5.0);
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_STOP);
- current_pose.set("4d70e328-48b6-dc6a-0be1-85dd6b333e81");
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_START);
+ set_current_pose("4d70e328-48b6-dc6a-0be1-85dd6b333e81");
}
void handle_pose_stand_lhao(void*)
{
- gSavedSettings.setF32("AscentAvatarZModifier", 5.0);
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_STOP);
- current_pose.set("f088eaf0-f1c9-8cf1-99c8-09df96bb13ae");
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_START);
+ set_current_pose("f088eaf0-f1c9-8cf1-99c8-09df96bb13ae");
}
void handle_pose_stand_stop(void*)
{
- gSavedSettings.setF32("AscentAvatarZModifier", 0.0);
- gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_STOP);
- current_pose = LLUUID::null;
+ if (current_pose != LLUUID::null)
+ {
+ gSavedSettings.setF32("AscentAvatarZModifier", gSavedSettings.getF32("AscentAvatarZModifier") - 7.5);
+ gAgent.sendAgentSetAppearance();
+ gAgent.sendAnimationRequest(current_pose, ANIM_REQUEST_STOP);
+ current_pose = LLUUID::null;
+ }
}
// ---------------------------------------------------
diff --git a/indra/newview/skins/default/xui/en-us/panel_preferences_ascent_system.xml b/indra/newview/skins/default/xui/en-us/panel_preferences_ascent_system.xml
index be54e139f..372ac12e7 100644
--- a/indra/newview/skins/default/xui/en-us/panel_preferences_ascent_system.xml
+++ b/indra/newview/skins/default/xui/en-us/panel_preferences_ascent_system.xml
@@ -372,6 +372,31 @@
+ Pivot Point
+
+
+
+
+
+
diff --git a/indra/newview/skins/default/xui/en-us/panel_preferences_ascent_vanity.xml b/indra/newview/skins/default/xui/en-us/panel_preferences_ascent_vanity.xml
index 0e012d850..3a52f45f2 100644
--- a/indra/newview/skins/default/xui/en-us/panel_preferences_ascent_vanity.xml
+++ b/indra/newview/skins/default/xui/en-us/panel_preferences_ascent_vanity.xml
@@ -155,6 +155,24 @@
decimal_digits="0" enabled="true" follows="left|top" height="18" increment="1"
label="Breast min vel:" label_width="100" max_val="100" min_val="1" mouse_opaque="true"
show_text="true" width="250" auto_resize="false" tool_tip=""/>
+
+ Avatar Offset Modifiers
+
+
+
+