mirror of
https://github.com/bdunderscore/modular-avatar.git
synced 2025-01-01 20:25:07 +08:00
5359e3b006
* add referenced assembly * remove unused usings * MA Merge Blend Tree is VRC specific because it expects VRC style Animator Layer setup * PruneParametersPass is VRChat specific * fix: use FindAvatarTransformInParents() to be more cross platform * fix MergeArmatureHook: nop logic for PhysBones if we do not dedup PhysBones * fix AnimatorCombiner: ignore VRC components when non-VRC btw, is AnimatorCombiner VRC specific? * conditional compile some VRChat specific tests
21 lines
585 B
C#
21 lines
585 B
C#
#if MA_VRCSDK3_AVATARS
|
|
|
|
using System.Linq;
|
|
using nadena.dev.ndmf;
|
|
|
|
namespace nadena.dev.modular_avatar.core.editor
|
|
{
|
|
internal class PruneParametersPass : Pass<PruneParametersPass>
|
|
{
|
|
protected override void Execute(ndmf.BuildContext context)
|
|
{
|
|
var expParams = context.AvatarDescriptor.expressionParameters;
|
|
if (expParams != null && context.IsTemporaryAsset(expParams))
|
|
{
|
|
expParams.parameters = expParams.parameters.Where(p => !string.IsNullOrEmpty(p.name)).ToArray();
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
#endif |