From e0cb5438a5055c71191c6ae6b27c7dee63e40562 Mon Sep 17 00:00:00 2001
From: "Brad Payne (Vir Linden)" <vir@lindenlab.com>
Date: Fri, 6 May 2016 10:17:56 -0400
Subject: [PATCH] SL-315 - notes on resetSkeleton()

---
 indra/newview/llvoavatar.cpp | 17 ++++++++++++++++-
 1 file changed, 16 insertions(+), 1 deletion(-)

diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp
index 679ea88a44c..d44c7f56f2d 100755
--- a/indra/newview/llvoavatar.cpp
+++ b/indra/newview/llvoavatar.cpp
@@ -1808,16 +1808,24 @@ void LLVOAvatar::resetSkeleton()
 {
     LL_DEBUGS("Avatar") << avString() << LL_ENDL;
 
-    // Reset params
+    // Stop all animations
+
+    // Clear all attachment pos overrides
+
+    // Preserve state of tweakable params
+    
+    // Reset all params to default state, without propagating changes downstream.
 	for (LLVisualParam *param = getFirstVisualParam(); 
 		param;
 		param = getNextVisualParam())
 	{
+#if 0
 		if (param->isAnimating())
 		{
 			continue;
 		}
         param->setLastWeight(param->getDefaultWeight());
+#endif
 	}
 
     // Reset all bones and collision volumes to their initial skeleton state.
@@ -1826,8 +1834,15 @@ void LLVOAvatar::resetSkeleton()
         LL_ERRS() << "Error resetting skeleton" << LL_ENDL;
 	}
 
+    // Reset tweakable params to preserved state
     // Apply params
+#if 0
     updateVisualParams();
+#endif
+
+    // Restore attachment pos overrides
+
+    // Restart animations
 }
 
 //-----------------------------------------------------------------------------
-- 
GitLab