summaryrefslogtreecommitdiff
path: root/indra/newview/llvoavatar.cpp
diff options
context:
space:
mode:
authorErik Kundiman <erik@megapahit.org>2026-08-12 18:35:14 +0800
committerErik Kundiman <erik@megapahit.org>2026-08-12 18:35:14 +0800
commita0ec1334e0bc8c166114ae6cc8cf105eb64dcbd6 (patch)
tree51cce5dacb6f08fbdb5bce1c3c9d20cdd3405e12 /indra/newview/llvoavatar.cpp
parente027be6fafd38fcf7d1a989f705eea7a6d37837f (diff)
Option to disable the pre-jump & land animationsHEADmain
https://megapahit.com/show_bug.cgi?id=21 Returning false is for disabling, setting AGENT_CONTROL_FINISH_ANIM is to not get stuck.
Diffstat (limited to 'indra/newview/llvoavatar.cpp')
-rw-r--r--indra/newview/llvoavatar.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp
index 16f2064d1b..f0fa1d782e 100644
--- a/indra/newview/llvoavatar.cpp
+++ b/indra/newview/llvoavatar.cpp
@@ -6374,6 +6374,7 @@ LLUUID LLVOAvatar::remapMotionID(const LLUUID& id)
// virtual
bool LLVOAvatar::startMotion(const LLUUID& id, F32 time_offset)
{
+ static LLCachedControl<bool> disable_pre_jump_land(gSavedSettings, "DisablePreJumpLand");
LL_DEBUGS("Motion") << "motion requested " << id.asString() << " " << gAnimLibrary.animationName(id) << LL_ENDL;
LLUUID remap_id = remapMotionID(id);
@@ -6383,9 +6384,17 @@ bool LLVOAvatar::startMotion(const LLUUID& id, F32 time_offset)
LL_DEBUGS("Motion") << "motion resultant " << remap_id.asString() << " " << gAnimLibrary.animationName(remap_id) << LL_ENDL;
}
- if (isSelf() && remap_id == ANIM_AGENT_AWAY)
+ if (isSelf())
{
+ if (remap_id == ANIM_AGENT_AWAY)
+ {
gAgent.setAFK();
+ }
+ else if (disable_pre_jump_land && (remap_id == ANIM_AGENT_PRE_JUMP || remap_id == ANIM_AGENT_LAND || remap_id == ANIM_AGENT_MEDIUM_LAND))
+ {
+ gAgent.setControlFlags(AGENT_CONTROL_FINISH_ANIM);
+ return false;
+ }
}
return LLCharacter::startMotion(remap_id, time_offset);