summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorAimee Linden <aimee@lindenlab.com>2010-06-28 18:40:00 +0100
committerAimee Linden <aimee@lindenlab.com>2010-06-28 18:40:00 +0100
commit589c6743c1a1467e5af3f1ef44af643d6b21e3a4 (patch)
treea991e7b6359f6ac8e0192a83723788824924529c /indra
parent49209dfd7123515d76f9598149c1c724d0c0825a (diff)
parent3b612cd369a2e9c1e380c21ee65c143c826bfcda (diff)
Merge
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/app_settings/settings.xml11
-rw-r--r--indra/newview/llviewerjoystick.cpp8
2 files changed, 14 insertions, 5 deletions
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml
index d3cc5d6cb7..1eb3732e65 100644
--- a/indra/newview/app_settings/settings.xml
+++ b/indra/newview/app_settings/settings.xml
@@ -3309,6 +3309,17 @@
<key>Value</key>
<real>1.0</real>
</map>
+ <key>FlycamBuildModeScale</key>
+ <map>
+ <key>Comment</key>
+ <string>Scale factor to apply to flycam movements when in build mode.</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>F32</string>
+ <key>Value</key>
+ <real>1.0</real>
+ </map>
<key>FlycamFeathering</key>
<map>
<key>Comment</key>
diff --git a/indra/newview/llviewerjoystick.cpp b/indra/newview/llviewerjoystick.cpp
index 240a539f2e..79d8fc7df9 100644
--- a/indra/newview/llviewerjoystick.cpp
+++ b/indra/newview/llviewerjoystick.cpp
@@ -57,9 +57,6 @@
#define RY_I 5
#define RZ_I 3
-// flycam translations in build mode should be reduced
-const F32 BUILDMODE_FLYCAM_T_SCALE = 3.f;
-
// minimum time after setting away state before coming back
const F32 MIN_AFK_TIME = 2.f;
@@ -924,14 +921,15 @@ void LLViewerJoystick::moveFlycam(bool reset)
cur_delta[i] = llmin(cur_delta[i]+dead_zone[i], 0.f);
}
- // we need smaller camera movements in build mode
+ // We may want to scale camera movements up or down in build mode.
// NOTE: this needs to remain after the deadzone calculation, otherwise
// we have issues with flycam "jumping" when the build dialog is opened/closed -Nyx
if (in_build_mode)
{
if (i == X_I || i == Y_I || i == Z_I)
{
- cur_delta[i] /= BUILDMODE_FLYCAM_T_SCALE;
+ static LLCachedControl<F32> build_mode_scale(gSavedSettings,"FlycamBuildModeScale");
+ cur_delta[i] *= build_mode_scale;
}
}