mirror of
https://github.com/bdunderscore/modular-avatar.git
synced 2025-02-12 08:42:48 +08:00
chore: ignore inactive root in GetTargetGroups
This commit is contained in:
parent
89d38c5371
commit
8414d203e5
@ -18,7 +18,8 @@ namespace nadena.dev.modular_avatar.core.editor
|
||||
|
||||
public ImmutableList<RenderGroup> GetTargetGroups(ComputeContext context)
|
||||
{
|
||||
var roots = context.GetAvatarRoots();
|
||||
var roots = context.GetAvatarRoots()
|
||||
.Where(r => context.ActiveInHierarchy(r) is true);
|
||||
var removers = roots
|
||||
.SelectMany(r => context.GetComponentsInChildren<ModularAvatarRemoveVertexColor>(r, true))
|
||||
.Select(rvc => (ToPathString(context, rvc.transform),
|
||||
|
@ -1,4 +1,4 @@
|
||||
#region
|
||||
#region
|
||||
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.Immutable;
|
||||
@ -63,6 +63,11 @@ namespace nadena.dev.modular_avatar.core.editor
|
||||
|
||||
foreach (var root in ctx.GetAvatarRoots())
|
||||
{
|
||||
if (ctx.ActiveInHierarchy(root) is false)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
if (ctx.GetComponentsInChildren<ModularAvatarScaleAdjuster>(root, true).Length == 0)
|
||||
{
|
||||
continue;
|
||||
|
Loading…
Reference in New Issue
Block a user