Add ear morph with physics support
This commit is contained in:
@@ -49,6 +49,28 @@ AnimatorState:
|
||||
m_MirrorParameter:
|
||||
m_CycleOffsetParameter:
|
||||
m_TimeParameter: animSpeed
|
||||
--- !u!1101 &-971734861674072838
|
||||
AnimatorStateTransition:
|
||||
m_ObjectHideFlags: 1
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name:
|
||||
m_Conditions: []
|
||||
m_DstStateMachine: {fileID: 0}
|
||||
m_DstState: {fileID: 5228601998091799676}
|
||||
m_Solo: 0
|
||||
m_Mute: 0
|
||||
m_IsExit: 0
|
||||
serializedVersion: 3
|
||||
m_TransitionDuration: 0
|
||||
m_TransitionOffset: 0
|
||||
m_ExitTime: 1
|
||||
m_HasExitTime: 1
|
||||
m_HasFixedDuration: 1
|
||||
m_InterruptionSource: 0
|
||||
m_OrderedInterruption: 1
|
||||
m_CanTransitionToSelf: 1
|
||||
--- !u!91 &9100000
|
||||
AnimatorController:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -64,18 +86,6 @@ AnimatorController:
|
||||
m_DefaultInt: 0
|
||||
m_DefaultBool: 0
|
||||
m_Controller: {fileID: 9100000}
|
||||
- m_Name: next
|
||||
m_Type: 9
|
||||
m_DefaultFloat: 0
|
||||
m_DefaultInt: 0
|
||||
m_DefaultBool: 0
|
||||
m_Controller: {fileID: 9100000}
|
||||
- m_Name: next_s
|
||||
m_Type: 9
|
||||
m_DefaultFloat: 0
|
||||
m_DefaultInt: 0
|
||||
m_DefaultBool: 0
|
||||
m_Controller: {fileID: 9100000}
|
||||
m_AnimatorLayers:
|
||||
- serializedVersion: 5
|
||||
m_Name: Base Layer
|
||||
@@ -89,6 +99,18 @@ AnimatorController:
|
||||
m_IKPass: 0
|
||||
m_SyncedLayerAffectsTiming: 0
|
||||
m_Controller: {fileID: 9100000}
|
||||
- serializedVersion: 5
|
||||
m_Name: Ear Layer
|
||||
m_StateMachine: {fileID: 3753690335887328880}
|
||||
m_Mask: {fileID: 0}
|
||||
m_Motions: []
|
||||
m_Behaviours: []
|
||||
m_BlendingMode: 0
|
||||
m_SyncedLayerIndex: -1
|
||||
m_DefaultWeight: 1
|
||||
m_IKPass: 0
|
||||
m_SyncedLayerAffectsTiming: 0
|
||||
m_Controller: {fileID: 9100000}
|
||||
--- !u!1107 &1917244892325702502
|
||||
AnimatorStateMachine:
|
||||
serializedVersion: 6
|
||||
@@ -111,3 +133,52 @@ AnimatorStateMachine:
|
||||
m_ExitPosition: {x: 800, y: 120, z: 0}
|
||||
m_ParentStateMachinePosition: {x: 800, y: 20, z: 0}
|
||||
m_DefaultState: {fileID: -1046042063806159501}
|
||||
--- !u!1107 &3753690335887328880
|
||||
AnimatorStateMachine:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 1
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: Ear Layer
|
||||
m_ChildStates:
|
||||
- serializedVersion: 1
|
||||
m_State: {fileID: 5228601998091799676}
|
||||
m_Position: {x: 310, y: 160, z: 0}
|
||||
m_ChildStateMachines: []
|
||||
m_AnyStateTransitions: []
|
||||
m_EntryTransitions: []
|
||||
m_StateMachineTransitions: {}
|
||||
m_StateMachineBehaviours: []
|
||||
m_AnyStatePosition: {x: 50, y: 20, z: 0}
|
||||
m_EntryPosition: {x: 50, y: 120, z: 0}
|
||||
m_ExitPosition: {x: 800, y: 120, z: 0}
|
||||
m_ParentStateMachinePosition: {x: 800, y: 20, z: 0}
|
||||
m_DefaultState: {fileID: 5228601998091799676}
|
||||
--- !u!1102 &5228601998091799676
|
||||
AnimatorState:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 1
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: motion_1
|
||||
m_Speed: 1
|
||||
m_CycleOffset: 0
|
||||
m_Transitions:
|
||||
- {fileID: -971734861674072838}
|
||||
m_StateMachineBehaviours: []
|
||||
m_Position: {x: 50, y: 50, z: 0}
|
||||
m_IKOnFeet: 0
|
||||
m_WriteDefaultValues: 1
|
||||
m_Mirror: 0
|
||||
m_SpeedParameterActive: 0
|
||||
m_MirrorParameterActive: 0
|
||||
m_CycleOffsetParameterActive: 0
|
||||
m_TimeParameterActive: 0
|
||||
m_Motion: {fileID: 7400000, guid: ad7fc1d5eece1a946a437cd1bb81bf90, type: 2}
|
||||
m_Tag:
|
||||
m_SpeedParameter:
|
||||
m_MirrorParameter:
|
||||
m_CycleOffsetParameter:
|
||||
m_TimeParameter:
|
||||
|
||||
@@ -955,81 +955,6 @@ CanvasRenderer:
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 69389580}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &70184842
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 70184843}
|
||||
- component: {fileID: 70184845}
|
||||
- component: {fileID: 70184844}
|
||||
m_Layer: 5
|
||||
m_Name: Checkmark
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &70184843
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 70184842}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 1635973781}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 35, y: 35}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &70184844
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 70184842}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_Sprite: {fileID: 10901, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_Type: 0
|
||||
m_PreserveAspect: 0
|
||||
m_FillCenter: 1
|
||||
m_FillMethod: 4
|
||||
m_FillAmount: 1
|
||||
m_FillClockwise: 1
|
||||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
m_PixelsPerUnitMultiplier: 1
|
||||
--- !u!222 &70184845
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 70184842}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &71219874
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -10519,14 +10444,13 @@ RectTransform:
|
||||
- {fileID: 1798338064}
|
||||
- {fileID: 482905334}
|
||||
- {fileID: 1424772036}
|
||||
- {fileID: 1333306137}
|
||||
m_Father: {fileID: 1704906816}
|
||||
m_RootOrder: 3
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 0, y: 0}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 0, y: 200}
|
||||
m_SizeDelta: {x: 0, y: 150.52}
|
||||
m_Pivot: {x: 1, y: 0.5}
|
||||
--- !u!114 &548276325
|
||||
MonoBehaviour:
|
||||
@@ -21981,8 +21905,8 @@ MonoBehaviour:
|
||||
m_TargetGraphic: {fileID: 1882365343}
|
||||
m_HandleRect: {fileID: 1882365342}
|
||||
m_Direction: 2
|
||||
m_Value: 1
|
||||
m_Size: 0.88527817
|
||||
m_Value: 0.9999985
|
||||
m_Size: 0.925002
|
||||
m_NumberOfSteps: 0
|
||||
m_OnValueChanged:
|
||||
m_PersistentCalls:
|
||||
@@ -23142,104 +23066,6 @@ MonoBehaviour:
|
||||
m_EditorClassIdentifier:
|
||||
m_HorizontalFit: 0
|
||||
m_VerticalFit: 2
|
||||
--- !u!1 &1252885463
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 1252885464}
|
||||
- component: {fileID: 1252885465}
|
||||
m_Layer: 5
|
||||
m_Name: Toggle
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &1252885464
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1252885463}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 1635973781}
|
||||
- {fileID: 1301256969}
|
||||
m_Father: {fileID: 1333306137}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 160, y: 20}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &1252885465
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1252885463}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 9085046f02f69544eb97fd06b6048fe2, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Navigation:
|
||||
m_Mode: 3
|
||||
m_WrapAround: 0
|
||||
m_SelectOnUp: {fileID: 0}
|
||||
m_SelectOnDown: {fileID: 0}
|
||||
m_SelectOnLeft: {fileID: 0}
|
||||
m_SelectOnRight: {fileID: 0}
|
||||
m_Transition: 1
|
||||
m_Colors:
|
||||
m_NormalColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
|
||||
m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1}
|
||||
m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
|
||||
m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608}
|
||||
m_ColorMultiplier: 1
|
||||
m_FadeDuration: 0.1
|
||||
m_SpriteState:
|
||||
m_HighlightedSprite: {fileID: 0}
|
||||
m_PressedSprite: {fileID: 0}
|
||||
m_SelectedSprite: {fileID: 0}
|
||||
m_DisabledSprite: {fileID: 0}
|
||||
m_AnimationTriggers:
|
||||
m_NormalTrigger: Normal
|
||||
m_HighlightedTrigger: Highlighted
|
||||
m_PressedTrigger: Pressed
|
||||
m_SelectedTrigger: Selected
|
||||
m_DisabledTrigger: Disabled
|
||||
m_Interactable: 1
|
||||
m_TargetGraphic: {fileID: 1635973782}
|
||||
toggleTransition: 1
|
||||
graphic: {fileID: 70184844}
|
||||
m_Group: {fileID: 0}
|
||||
onValueChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls:
|
||||
- m_Target: {fileID: 1564959567}
|
||||
m_TargetAssemblyTypeName: UmaViewerUI, umamusume
|
||||
m_MethodName: SetEarMorphEnable
|
||||
m_Mode: 0
|
||||
m_Arguments:
|
||||
m_ObjectArgument: {fileID: 0}
|
||||
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
|
||||
m_IntArgument: 0
|
||||
m_FloatArgument: 0
|
||||
m_StringArgument:
|
||||
m_BoolArgument: 0
|
||||
m_CallState: 2
|
||||
m_IsOn: 0
|
||||
--- !u!1 &1255010893
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -24274,140 +24100,6 @@ RectTransform:
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 0, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!1 &1301256968
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 1301256969}
|
||||
- component: {fileID: 1301256971}
|
||||
- component: {fileID: 1301256970}
|
||||
m_Layer: 5
|
||||
m_Name: Text (TMP)
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &1301256969
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1301256968}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 1252885464}
|
||||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
m_AnchoredPosition: {x: -22.849878, y: 0}
|
||||
m_SizeDelta: {x: 45.700245, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &1301256970
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1301256968}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_text: Ear Morph Override
|
||||
m_isRightToLeft: 0
|
||||
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
|
||||
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
|
||||
m_fontSharedMaterials: []
|
||||
m_fontMaterial: {fileID: 0}
|
||||
m_fontMaterials: []
|
||||
m_fontColor32:
|
||||
serializedVersion: 2
|
||||
rgba: 4294967295
|
||||
m_fontColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_enableVertexGradient: 0
|
||||
m_colorMode: 3
|
||||
m_fontColorGradient:
|
||||
topLeft: {r: 1, g: 1, b: 1, a: 1}
|
||||
topRight: {r: 1, g: 1, b: 1, a: 1}
|
||||
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
|
||||
bottomRight: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_fontColorGradientPreset: {fileID: 0}
|
||||
m_spriteAsset: {fileID: 0}
|
||||
m_tintAllSprites: 0
|
||||
m_StyleSheet: {fileID: 0}
|
||||
m_TextStyleHashCode: -1183493901
|
||||
m_overrideHtmlColors: 0
|
||||
m_faceColor:
|
||||
serializedVersion: 2
|
||||
rgba: 4294967295
|
||||
m_fontSize: 22
|
||||
m_fontSizeBase: 22
|
||||
m_fontWeight: 400
|
||||
m_enableAutoSizing: 0
|
||||
m_fontSizeMin: 18
|
||||
m_fontSizeMax: 72
|
||||
m_fontStyle: 0
|
||||
m_HorizontalAlignment: 2
|
||||
m_VerticalAlignment: 512
|
||||
m_textAlignment: 65535
|
||||
m_characterSpacing: 0
|
||||
m_wordSpacing: 0
|
||||
m_lineSpacing: 0
|
||||
m_lineSpacingMax: 0
|
||||
m_paragraphSpacing: 0
|
||||
m_charWidthMaxAdj: 0
|
||||
m_enableWordWrapping: 1
|
||||
m_wordWrappingRatios: 0.4
|
||||
m_overflowMode: 0
|
||||
m_linkedTextComponent: {fileID: 0}
|
||||
parentLinkedComponent: {fileID: 0}
|
||||
m_enableKerning: 1
|
||||
m_enableExtraPadding: 0
|
||||
checkPaddingRequired: 0
|
||||
m_isRichText: 1
|
||||
m_parseCtrlCharacters: 1
|
||||
m_isOrthographic: 1
|
||||
m_isCullingEnabled: 0
|
||||
m_horizontalMapping: 0
|
||||
m_verticalMapping: 0
|
||||
m_uvLineOffset: 0
|
||||
m_geometrySortingOrder: 0
|
||||
m_IsTextObjectScaleStatic: 0
|
||||
m_VertexBufferAutoSizeReduction: 0
|
||||
m_useMaxVisibleDescender: 1
|
||||
m_pageToDisplay: 1
|
||||
m_margin: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_isUsingLegacyAnimationComponent: 0
|
||||
m_isVolumetricText: 0
|
||||
m_hasFontAssetChanged: 0
|
||||
m_baseMaterial: {fileID: 0}
|
||||
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
|
||||
--- !u!222 &1301256971
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1301256968}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &1301831364
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -24617,51 +24309,6 @@ CanvasRenderer:
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1323454210}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &1333306136
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 1333306137}
|
||||
- component: {fileID: 1333306139}
|
||||
m_Layer: 5
|
||||
m_Name: EarMoprh
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &1333306137
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1333306136}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 1252885464}
|
||||
m_Father: {fileID: 548276324}
|
||||
m_RootOrder: 3
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 1}
|
||||
m_AnchorMax: {x: 0, y: 1}
|
||||
m_AnchoredPosition: {x: 283, y: -175}
|
||||
m_SizeDelta: {x: 283, y: 50}
|
||||
m_Pivot: {x: 1, y: 0.5}
|
||||
--- !u!222 &1333306139
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1333306136}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &1339030789
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -29288,82 +28935,6 @@ CanvasRenderer:
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1625876556}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &1635973780
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 1635973781}
|
||||
- component: {fileID: 1635973783}
|
||||
- component: {fileID: 1635973782}
|
||||
m_Layer: 5
|
||||
m_Name: Background
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &1635973781
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1635973780}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 70184843}
|
||||
m_Father: {fileID: 1252885464}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 1, y: 0.5}
|
||||
m_AnchorMax: {x: 1, y: 0.5}
|
||||
m_AnchoredPosition: {x: 35.3, y: 0}
|
||||
m_SizeDelta: {x: 35, y: 35}
|
||||
m_Pivot: {x: 1, y: 0.5}
|
||||
--- !u!114 &1635973782
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1635973780}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_Type: 1
|
||||
m_PreserveAspect: 0
|
||||
m_FillCenter: 1
|
||||
m_FillMethod: 4
|
||||
m_FillAmount: 1
|
||||
m_FillClockwise: 1
|
||||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
m_PixelsPerUnitMultiplier: 1
|
||||
--- !u!222 &1635973783
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1635973780}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &1636363194
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
||||
@@ -248,11 +248,11 @@ public class CameraOrbit : MonoBehaviour
|
||||
private void MobileOrbitLight()
|
||||
{
|
||||
return;
|
||||
if (Input.touchCount == 2 && !eventSystem.IsPointerOverGameObject(Input.touches[0].fingerId) && !eventSystem.IsPointerOverGameObject(Input.touches[1].fingerId))
|
||||
{
|
||||
Light.transform.Rotate(Input.GetAxis("Mouse X") * Vector3.up, Space.Self);
|
||||
Light.transform.Rotate(Input.GetAxis("Mouse Y") * Vector3.right, Space.Self);
|
||||
}
|
||||
//if (Input.touchCount == 2 && !eventSystem.IsPointerOverGameObject(Input.touches[0].fingerId) && !eventSystem.IsPointerOverGameObject(Input.touches[1].fingerId))
|
||||
//{
|
||||
// Light.transform.Rotate(Input.GetAxis("Mouse X") * Vector3.up, Space.Self);
|
||||
// Light.transform.Rotate(Input.GetAxis("Mouse Y") * Vector3.right, Space.Self);
|
||||
//}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -14,12 +14,13 @@ public class UmaContainer : MonoBehaviour
|
||||
public GameObject PhysicsController;
|
||||
|
||||
public List<Texture2D> TailTextures = new List<Texture2D>();
|
||||
|
||||
[Header("Animator")]
|
||||
public Animator UmaAnimator;
|
||||
public AnimatorOverrideController OverrideController;
|
||||
|
||||
public bool isAnimatorControl;
|
||||
public Animator UmaFaceAnimator;
|
||||
public AnimatorOverrideController FaceOverrideController;
|
||||
public bool isAnimatorControl;
|
||||
|
||||
[Header("Face")]
|
||||
public FaceDrivenKeyTarget FaceDrivenKeyTarget;
|
||||
@@ -38,6 +39,10 @@ public class UmaContainer : MonoBehaviour
|
||||
public bool IsMini = false;
|
||||
public List<Texture2D> MiniHeadTextures = new List<Texture2D>();
|
||||
|
||||
[Header("Physics")]
|
||||
public bool EnablePhysics = true;
|
||||
public List<CySpringDataContainer> cySpringDataContainers;
|
||||
|
||||
public void MergeModel()
|
||||
{
|
||||
if (!Body) return;
|
||||
@@ -127,16 +132,28 @@ public class UmaContainer : MonoBehaviour
|
||||
|
||||
public void LoadPhysics()
|
||||
{
|
||||
cySpringDataContainers = new List<CySpringDataContainer>();
|
||||
var springs = PhysicsController.GetComponentsInChildren<CySpringDataContainer>();
|
||||
foreach (CySpringDataContainer spring in springs)
|
||||
{
|
||||
cySpringDataContainers.Add(spring);
|
||||
spring.InitializePhysics();
|
||||
}
|
||||
}
|
||||
|
||||
public void SetDynamicBoneEnable(bool isOn)
|
||||
{
|
||||
if (IsMini) return;
|
||||
EnablePhysics = isOn;
|
||||
foreach (CySpringDataContainer cySpring in cySpringDataContainers)
|
||||
{
|
||||
cySpring.EnablePhysics(isOn);
|
||||
}
|
||||
}
|
||||
|
||||
private void FixedUpdate()
|
||||
{
|
||||
if (TrackTarget&& EnableEyeTracking && !IsMini)
|
||||
if (TrackTarget && EnableEyeTracking && !isAnimatorControl && !IsMini)
|
||||
{
|
||||
var targetPosotion = TrackTarget.transform.position - HeadBone.transform.up*EyeHeight;
|
||||
var deltaPos = HeadBone.transform.InverseTransformPoint(targetPosotion);
|
||||
|
||||
@@ -271,6 +271,9 @@ public class UmaViewerBuilder : MonoBehaviour
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
CurrentUMAContainer.LoadPhysics(); //Need to load physics before loading FacialMorph
|
||||
|
||||
//Load FacialMorph
|
||||
if (CurrentUMAContainer.Head)
|
||||
{
|
||||
@@ -294,7 +297,6 @@ public class UmaViewerBuilder : MonoBehaviour
|
||||
|
||||
|
||||
CurrentUMAContainer.MergeModel();
|
||||
CurrentUMAContainer.LoadPhysics();
|
||||
LoadAsset(UmaViewerMain.Instance.AbMotions.FirstOrDefault(a => a.Name.EndsWith($"anm_eve_chr{id}_00_idle01_loop")));
|
||||
}
|
||||
|
||||
@@ -971,6 +973,11 @@ public class UmaViewerBuilder : MonoBehaviour
|
||||
CurrentUMAContainer.isAnimatorControl = true;
|
||||
CurrentUMAContainer.UmaFaceAnimator.Play("motion_1", 0, 0);
|
||||
}
|
||||
else if (clip.name.Contains("ear"))
|
||||
{
|
||||
CurrentUMAContainer.FaceOverrideController["clip_2"] = clip;
|
||||
CurrentUMAContainer.UmaFaceAnimator.Play("motion_1", 1, 0);
|
||||
}
|
||||
else if (clip.name.Contains("cam"))
|
||||
{
|
||||
var overrideController = Instantiate(CameraOverrideController);
|
||||
@@ -988,12 +995,17 @@ public class UmaViewerBuilder : MonoBehaviour
|
||||
{
|
||||
var facialMotion = Main.AbMotions.FirstOrDefault(a => a.Name.EndsWith(clip.name + "_face"));
|
||||
var cameraMotion = Main.AbMotions.FirstOrDefault(a => a.Name.EndsWith(clip.name + "_cam"));
|
||||
|
||||
var earMotion = Main.AbMotions.FirstOrDefault(a => a.Name.EndsWith(clip.name + "_ear"));
|
||||
if (facialMotion != null)
|
||||
{
|
||||
RecursiveLoadAsset(facialMotion);
|
||||
}
|
||||
|
||||
if (earMotion != null)
|
||||
{
|
||||
RecursiveLoadAsset(earMotion);
|
||||
}
|
||||
|
||||
if (cameraMotion != null)
|
||||
{
|
||||
RecursiveLoadAsset(cameraMotion);
|
||||
|
||||
@@ -646,21 +646,7 @@ public class UmaViewerUI : MonoBehaviour
|
||||
{
|
||||
if (Builder.CurrentUMAContainer)
|
||||
{
|
||||
foreach(CySpringDataContainer cySpring in Builder.CurrentUMAContainer.GetComponentsInChildren<CySpringDataContainer>())
|
||||
{
|
||||
cySpring.EnablePhysics(isOn);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void SetEarMorphEnable(bool isOn)
|
||||
{
|
||||
if (Builder.CurrentUMAContainer)
|
||||
{
|
||||
foreach (CySpringDataContainer cySpring in Builder.CurrentUMAContainer.GetComponentsInChildren<CySpringDataContainer>())
|
||||
{
|
||||
cySpring.EnableEarPhysics(!isOn);
|
||||
}
|
||||
Builder.CurrentUMAContainer.SetDynamicBoneEnable(isOn);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -749,7 +735,8 @@ public class UmaViewerUI : MonoBehaviour
|
||||
if (animator_face)
|
||||
{
|
||||
animator_face.speed = AnimationSpeedSlider.value;
|
||||
animator_face.Play(0, -1, 0);
|
||||
animator_face.Play(0, 0, 0);
|
||||
animator_face.Play(0, 1, 0);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -774,7 +761,8 @@ public class UmaViewerUI : MonoBehaviour
|
||||
if (animator_face)
|
||||
{
|
||||
animator_face.speed = 0;
|
||||
animator_face.Play(0, -1, val);
|
||||
animator_face.Play(0, 0, val);
|
||||
animator_face.Play(0, 1, val);
|
||||
}
|
||||
|
||||
AnimationProgressText.text = string.Format("{0} / {1}", ToFrameFormat(val * AnimeClip.length, AnimeClip.frameRate), ToFrameFormat(AnimeClip.length, AnimeClip.frameRate));
|
||||
|
||||
@@ -103,8 +103,8 @@ namespace Gallop
|
||||
else
|
||||
{
|
||||
dynamic.m_Damping = 0.2f;
|
||||
dynamic.m_Stiffness = Mathf.Clamp01(40 / spring._stiffnessForce);
|
||||
dynamic.m_Elasticity = Mathf.Clamp01(40 / spring._dragForce);
|
||||
dynamic.m_Stiffness = Mathf.Clamp01(45 / spring._stiffnessForce);
|
||||
dynamic.m_Elasticity = Mathf.Clamp01(45 / spring._dragForce);
|
||||
|
||||
}
|
||||
dynamic.m_Radius = spring._collisionRadius;
|
||||
@@ -125,7 +125,6 @@ namespace Gallop
|
||||
var tempParticle = dynamic.Particles.Find(a => { return a.m_Transform.gameObject.name == Childcollision._boneName; });
|
||||
if (tempParticle != null)
|
||||
{
|
||||
tempParticle.m_Damping = 0.2f;
|
||||
if (isTail)
|
||||
{
|
||||
tempParticle.m_Damping = 0.1f;
|
||||
@@ -135,8 +134,8 @@ namespace Gallop
|
||||
else
|
||||
{
|
||||
tempParticle.m_Damping = 0.2f;
|
||||
tempParticle.m_Stiffness = Mathf.Clamp01(40 / spring._stiffnessForce);
|
||||
tempParticle.m_Elasticity = Mathf.Clamp01(40 / spring._dragForce);
|
||||
tempParticle.m_Stiffness = Mathf.Clamp01(45 / spring._stiffnessForce);
|
||||
tempParticle.m_Elasticity = Mathf.Clamp01(45 / spring._dragForce);
|
||||
}
|
||||
tempParticle.m_Radius = Childcollision._collisionRadius;
|
||||
foreach (string collisionName in Childcollision._collisionNameList)
|
||||
@@ -158,21 +157,7 @@ namespace Gallop
|
||||
{
|
||||
foreach(DynamicBone dynamic in DynamicBones)
|
||||
{
|
||||
if (!dynamic.m_Root.name.Contains("Ear"))
|
||||
{
|
||||
dynamic.enabled = isOn;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void EnableEarPhysics(bool isOn)
|
||||
{
|
||||
foreach (DynamicBone dynamic in DynamicBones)
|
||||
{
|
||||
if (dynamic.m_Root.name.Contains("Ear"))
|
||||
{
|
||||
dynamic.enabled = isOn;
|
||||
}
|
||||
dynamic.enabled = isOn;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@ using Gallop.Live.Cutt;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using static DynamicBone;
|
||||
|
||||
namespace Gallop
|
||||
{
|
||||
@@ -25,15 +26,25 @@ namespace Gallop
|
||||
public List<FacialMorph> MouthMorphs = new List<FacialMorph>();
|
||||
|
||||
public GameObject DrivenKeyLocator;
|
||||
public GameObject EyeballCtrl_L_Locator, EyeballCtrl_R_Locator, EyeballCtrl_All_Locator;
|
||||
|
||||
public UmaContainer Container;
|
||||
|
||||
Dictionary<Transform, Vector3> RotationRecorder = new Dictionary<Transform, Vector3>();
|
||||
|
||||
Dictionary<Particle, Vector3> ParticleRecorder = new Dictionary<Particle, Vector3>();
|
||||
public void Initialize(List<Transform> objs)
|
||||
{
|
||||
Objs = objs;
|
||||
|
||||
List<Particle> particles = new List<Particle>();
|
||||
foreach (CySpringDataContainer spring in Container.cySpringDataContainers)
|
||||
{
|
||||
foreach (DynamicBone dynamicBone in spring.DynamicBones)
|
||||
{
|
||||
particles.AddRange(dynamicBone.Particles);
|
||||
}
|
||||
}
|
||||
|
||||
for (int i = 0; i < _earTarget.Count; i++)
|
||||
{
|
||||
for (int j = 0; j < _earTarget[i]._faceGroupInfo.Count; j++)
|
||||
@@ -46,6 +57,12 @@ namespace Gallop
|
||||
morph.trsArray = _earTarget[i]._faceGroupInfo[j]._trsArray;
|
||||
foreach (TrsArray trs in morph.trsArray)
|
||||
{
|
||||
var physicsParticle = particles.Find(a => a.m_Transform.name.Equals(trs._path));
|
||||
if (physicsParticle != null)
|
||||
{
|
||||
trs.isPhysics = true;
|
||||
trs.physicsParticle = physicsParticle;
|
||||
}
|
||||
trs.transform = Objs.Find(ani => ani.name.Equals(trs._path));
|
||||
}
|
||||
if (i == 0)
|
||||
@@ -147,7 +164,7 @@ namespace Gallop
|
||||
}
|
||||
}
|
||||
}
|
||||
FacialResetAll();
|
||||
|
||||
ChangeMorphWeight(MouthMorphs[3], 1);
|
||||
SetupAnimator();
|
||||
if (UmaViewerUI.Instance)
|
||||
@@ -160,12 +177,26 @@ namespace Gallop
|
||||
{
|
||||
DrivenKeyLocator = new GameObject("DrivenKeyLocator");
|
||||
DrivenKeyLocator.transform.SetParent(Container.transform);
|
||||
SetupLocator("Ear_L_Ctrl", "Ear_L__", EarMorphs.FindAll(a => a.direction == true));
|
||||
SetupLocator("Ear_R_Ctrl", "Ear_R__", EarMorphs.FindAll(a => a.direction == false));
|
||||
SetupLocator("Eye_L_Base_Ctrl", "Eye_L__", EyeMorphs.FindAll(a => a.direction == true));
|
||||
SetupLocator("Eye_R_Base_Ctrl", "Eye_R__", EyeMorphs.FindAll(a => a.direction == false));
|
||||
SetupLocator("Eyebrow_L_Base_Ctrl", "Eyebrow_L__", EyeBrowMorphs.FindAll(a => a.direction == true));
|
||||
SetupLocator("Eyebrow_R_Base_Ctrl", "Eyebrow_R__", EyeBrowMorphs.FindAll(a => a.direction == false));
|
||||
SetupLocator("Mouth_Base_Ctrl", "Mouth__", MouthMorphs.FindAll(a => a.direction == false));
|
||||
|
||||
var root = new GameObject("Eyeball_L_Ctrl");
|
||||
root.transform.SetParent(DrivenKeyLocator.transform);
|
||||
EyeballCtrl_L_Locator = root;
|
||||
|
||||
root = new GameObject("Eyeball_R_Ctrl");
|
||||
root.transform.SetParent(DrivenKeyLocator.transform);
|
||||
EyeballCtrl_R_Locator = root;
|
||||
|
||||
root = new GameObject("Eyeball_all_Ctrl");
|
||||
root.transform.SetParent(DrivenKeyLocator.transform);
|
||||
EyeballCtrl_All_Locator = root;
|
||||
|
||||
Container.UmaFaceAnimator = DrivenKeyLocator.AddComponent<Animator>();
|
||||
Container.UmaFaceAnimator.avatar = AvatarBuilder.BuildGenericAvatar(DrivenKeyLocator, "DrivenKeyLocator");
|
||||
Container.FaceOverrideController = Instantiate(UmaViewerBuilder.Instance.FaceOverrideController);
|
||||
@@ -177,8 +208,9 @@ namespace Gallop
|
||||
var root = new GameObject(rootName);
|
||||
root.transform.SetParent(DrivenKeyLocator.transform);
|
||||
|
||||
morphs.ForEach(morph=>{
|
||||
var locator = new GameObject(prefix+morph.tag);
|
||||
morphs.ForEach(morph =>
|
||||
{
|
||||
var locator = new GameObject(prefix + morph.tag);
|
||||
locator.transform.SetParent(root.transform);
|
||||
morph.locator = locator.transform;
|
||||
});
|
||||
@@ -213,7 +245,6 @@ namespace Gallop
|
||||
|
||||
public void ClearMorph()
|
||||
{
|
||||
|
||||
foreach (FacialMorph morph in EarMorphs)
|
||||
{
|
||||
morph.weight = 0;
|
||||
@@ -239,12 +270,17 @@ namespace Gallop
|
||||
{
|
||||
foreach (TrsArray trs in morph.trsArray)
|
||||
{
|
||||
if (trs.transform)
|
||||
if (trs.isPhysics && Container.EnablePhysics)
|
||||
{
|
||||
trs.physicsParticle.m_InitLocalPosition += trs._position * morph.weight;
|
||||
ParticleRecorder[trs.physicsParticle] += trs._rotation * morph.weight;
|
||||
}
|
||||
else if(trs.transform)
|
||||
{
|
||||
trs.transform.localScale += trs._scale * morph.weight;
|
||||
trs.transform.localPosition += trs._position * morph.weight;
|
||||
RotationRecorder[trs.transform] += trs._rotation * morph.weight;
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -264,12 +300,17 @@ namespace Gallop
|
||||
{
|
||||
foreach (TrsArray trs in trsArrays)
|
||||
{
|
||||
if (trs.transform)
|
||||
if (trs.isPhysics && Container.EnablePhysics)
|
||||
{
|
||||
trs.physicsParticle.m_InitLocalPosition = trs._position;
|
||||
ParticleRecorder[trs.physicsParticle] = trs._rotation;
|
||||
}
|
||||
else if (trs.transform)
|
||||
{
|
||||
trs.transform.localPosition = trs._position;
|
||||
trs.transform.localScale = trs._scale;
|
||||
RotationRecorder[trs.transform] = trs._rotation;
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -277,18 +318,25 @@ namespace Gallop
|
||||
{
|
||||
foreach (var trs in RotationRecorder)
|
||||
{
|
||||
trs.Key.localRotation = RotationConvert.fromMaya(trs.Value);
|
||||
trs.Key.transform.localRotation = RotationConvert.fromMaya(trs.Value);
|
||||
}
|
||||
if (Container.EnablePhysics)
|
||||
{
|
||||
foreach (var particle in ParticleRecorder)
|
||||
{
|
||||
particle.Key.m_InitLocalRotation = RotationConvert.fromMaya(particle.Value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void ChangeMorphWeight(FacialMorph morph,float val)
|
||||
public void ChangeMorphWeight(FacialMorph morph, float val)
|
||||
{
|
||||
Container.isAnimatorControl = false;
|
||||
morph.weight = val;
|
||||
ChangeMorph();
|
||||
}
|
||||
|
||||
public void SetEyeRange(float lx, float ly,float rx, float ry)
|
||||
|
||||
public void SetEyeRange(float lx, float ly, float rx, float ry)
|
||||
{
|
||||
LeftEyeXrange.weight = lx;
|
||||
LeftEyeYrange.weight = ly;
|
||||
@@ -303,44 +351,64 @@ namespace Gallop
|
||||
{
|
||||
morph.weight = morph.locator.transform.localPosition.x * -100;
|
||||
});
|
||||
EyeMorphs.ForEach(morph =>
|
||||
|
||||
EarMorphs.ForEach(morph =>
|
||||
{
|
||||
if (morph == LeftEyeXrange || morph == LeftEyeYrange || morph == RightEyeXrange || morph == RightEyeYrange)
|
||||
{
|
||||
if (!Container.EnableEyeTracking)
|
||||
{
|
||||
morph.weight = morph.locator.transform.localPosition.x * -100;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
morph.weight = morph.locator.transform.localPosition.x * -100;
|
||||
}
|
||||
morph.weight = morph.locator.transform.localPosition.x * -100;
|
||||
});
|
||||
|
||||
MouthMorphs.ForEach(morph =>
|
||||
{
|
||||
morph.weight = morph.locator.transform.localPosition.x * -100;
|
||||
});
|
||||
|
||||
EyeMorphs.ForEach(morph =>
|
||||
{
|
||||
if (!(morph == LeftEyeXrange || morph == LeftEyeYrange || morph == RightEyeXrange || morph == RightEyeYrange))
|
||||
{
|
||||
morph.weight = morph.locator.transform.localPosition.x * -100;
|
||||
}
|
||||
});
|
||||
|
||||
LeftEyeXrange.weight = -(EyeballCtrl_L_Locator.transform.localPosition.x * -100 + EyeballCtrl_All_Locator.transform.localPosition.x * -100);
|
||||
RightEyeXrange.weight = -(EyeballCtrl_R_Locator.transform.localPosition.x * -100 + EyeballCtrl_All_Locator.transform.localPosition.x * -100);
|
||||
|
||||
LeftEyeYrange.weight = -(EyeballCtrl_L_Locator.transform.localPosition.y * -100 + EyeballCtrl_All_Locator.transform.localPosition.y * -100);
|
||||
RightEyeYrange.weight = (EyeballCtrl_R_Locator.transform.localPosition.y * -100 + EyeballCtrl_All_Locator.transform.localPosition.y * -100);
|
||||
|
||||
ChangeMorph();
|
||||
}
|
||||
|
||||
|
||||
public void ResetLocator()
|
||||
{
|
||||
EarMorphs.ForEach(morph =>
|
||||
{
|
||||
morph.weight = 0;
|
||||
morph.locator.transform.localPosition = Vector3.zero;
|
||||
});
|
||||
|
||||
EyeBrowMorphs.ForEach(morph =>
|
||||
{
|
||||
morph.weight = 0;
|
||||
morph.locator.transform.localPosition = Vector3.zero;
|
||||
});
|
||||
|
||||
EyeMorphs.ForEach(morph =>
|
||||
{
|
||||
morph.weight = 0;
|
||||
morph.locator.transform.localPosition = Vector3.zero;
|
||||
});
|
||||
|
||||
MouthMorphs.ForEach(morph =>
|
||||
{
|
||||
morph.weight = 0;
|
||||
morph.locator.transform.localPosition = Vector3.zero;
|
||||
});
|
||||
|
||||
|
||||
EyeballCtrl_L_Locator.transform.localPosition = Vector3.zero;
|
||||
EyeballCtrl_R_Locator.transform.localPosition = Vector3.zero;
|
||||
EyeballCtrl_All_Locator.transform.localPosition = Vector3.zero;
|
||||
ChangeMorph();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
using Unity;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using static DynamicBone;
|
||||
|
||||
[System.Serializable]
|
||||
public class AssetTable
|
||||
@@ -40,6 +41,14 @@ public class TrsArray
|
||||
public Vector3 _scale;
|
||||
public Vector3 _rotation;
|
||||
public bool IsOverrideTarget;
|
||||
|
||||
public bool isPhysics;
|
||||
public Particle physicsParticle;
|
||||
|
||||
public override int GetHashCode()
|
||||
{
|
||||
return base.GetHashCode();
|
||||
}
|
||||
}
|
||||
|
||||
[System.Serializable]
|
||||
|
||||
Reference in New Issue
Block a user