mirror of
https://github.com/bdunderscore/modular-avatar.git
synced 2025-04-04 19:49:02 +08:00
parent
a71af7ae0a
commit
dd1a05086f
@ -35,7 +35,9 @@ namespace nadena.dev.modular_avatar.core.editor
|
||||
|
||||
public bool Inverted;
|
||||
|
||||
public bool IsConstant => ControllingConditions.Count == 0 || ControllingConditions.All(c => c.IsConstant);
|
||||
public bool IsConstant => ControllingConditions.Count == 0
|
||||
|| ControllingConditions.All(c => c.IsConstant)
|
||||
|| ControllingConditions.Any(c => c.IsConstant && !c.InitiallyActive);
|
||||
public bool IsConstantOn => IsConstant && InitiallyActive;
|
||||
|
||||
public override string ToString()
|
||||
|
@ -144,7 +144,7 @@ namespace nadena.dev.modular_avatar.core.editor
|
||||
HashSet<GameObject> toggledObjects = new();
|
||||
|
||||
if (asc == null) return;
|
||||
|
||||
|
||||
foreach (var targetProp in shapes.Keys)
|
||||
if (targetProp is { TargetObject: GameObject go, PropertyName: "m_IsActive" })
|
||||
toggledObjects.Add(go);
|
||||
|
@ -46,10 +46,13 @@ MonoBehaviour:
|
||||
m_EditorClassIdentifier:
|
||||
m_inverted: 0
|
||||
m_targetRenderer:
|
||||
referencePath: test mesh
|
||||
referencePath:
|
||||
targetObject: {fileID: 0}
|
||||
m_shapes:
|
||||
- ShapeName: key2
|
||||
- Object:
|
||||
referencePath: test mesh
|
||||
targetObject: {fileID: 0}
|
||||
ShapeName: key2
|
||||
ChangeType: 0
|
||||
Value: 100
|
||||
--- !u!1 &2598725701317979415
|
||||
@ -98,10 +101,13 @@ MonoBehaviour:
|
||||
m_EditorClassIdentifier:
|
||||
m_inverted: 0
|
||||
m_targetRenderer:
|
||||
referencePath: test mesh
|
||||
referencePath:
|
||||
targetObject: {fileID: 0}
|
||||
m_shapes:
|
||||
- ShapeName: key1
|
||||
- Object:
|
||||
referencePath: test mesh
|
||||
targetObject: {fileID: 0}
|
||||
ShapeName: key1
|
||||
ChangeType: 1
|
||||
Value: 10
|
||||
--- !u!1 &2845086157653980983
|
||||
@ -150,10 +156,13 @@ MonoBehaviour:
|
||||
m_EditorClassIdentifier:
|
||||
m_inverted: 0
|
||||
m_targetRenderer:
|
||||
referencePath: test mesh
|
||||
referencePath:
|
||||
targetObject: {fileID: 0}
|
||||
m_shapes:
|
||||
- ShapeName: key3
|
||||
- Object:
|
||||
referencePath: test mesh
|
||||
targetObject: {fileID: 0}
|
||||
ShapeName: key3
|
||||
ChangeType: 1
|
||||
Value: 100
|
||||
--- !u!1 &6385483934583485188
|
||||
@ -174,7 +183,7 @@ GameObject:
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &569625391371299408
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
@ -204,10 +213,13 @@ MonoBehaviour:
|
||||
m_EditorClassIdentifier:
|
||||
m_inverted: 0
|
||||
m_targetRenderer:
|
||||
referencePath: test mesh
|
||||
referencePath:
|
||||
targetObject: {fileID: 0}
|
||||
m_shapes:
|
||||
- ShapeName: key1
|
||||
- Object:
|
||||
referencePath: test mesh
|
||||
targetObject: {fileID: 0}
|
||||
ShapeName: key1
|
||||
ChangeType: 1
|
||||
Value: 20
|
||||
--- !u!114 &2918390808850211981
|
||||
@ -238,6 +250,7 @@ MonoBehaviour:
|
||||
isSynced: 1
|
||||
isSaved: 1
|
||||
isDefault: 0
|
||||
automaticValue: 0
|
||||
--- !u!114 &664065153831629983
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
|
Loading…
x
Reference in New Issue
Block a user