20231227动画更新
This commit is contained in:
parent
c4e5b14bac
commit
06f52d2ecf
File diff suppressed because it is too large
Load Diff
Binary file not shown.
|
@ -0,0 +1,100 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 5f61108e3668b3d43a2feb79ce02afa5
|
||||
ModelImporter:
|
||||
serializedVersion: 19301
|
||||
internalIDToNameTable:
|
||||
- first:
|
||||
74: 1827226128182048838
|
||||
second: Take 001
|
||||
externalObjects: {}
|
||||
materials:
|
||||
materialImportMode: 1
|
||||
materialName: 0
|
||||
materialSearch: 1
|
||||
materialLocation: 1
|
||||
animations:
|
||||
legacyGenerateAnimations: 4
|
||||
bakeSimulation: 0
|
||||
resampleCurves: 1
|
||||
optimizeGameObjects: 0
|
||||
motionNodeName:
|
||||
rigImportErrors:
|
||||
rigImportWarnings:
|
||||
animationImportErrors:
|
||||
animationImportWarnings:
|
||||
animationRetargetingWarnings:
|
||||
animationDoRetargetingWarnings: 0
|
||||
importAnimatedCustomProperties: 0
|
||||
importConstraints: 0
|
||||
animationCompression: 3
|
||||
animationRotationError: 0.5
|
||||
animationPositionError: 0.5
|
||||
animationScaleError: 0.5
|
||||
animationWrapMode: 0
|
||||
extraExposedTransformPaths: []
|
||||
extraUserProperties: []
|
||||
clipAnimations: []
|
||||
isReadable: 0
|
||||
meshes:
|
||||
lODScreenPercentages: []
|
||||
globalScale: 1
|
||||
meshCompression: 0
|
||||
addColliders: 0
|
||||
useSRGBMaterialColor: 1
|
||||
sortHierarchyByName: 1
|
||||
importVisibility: 1
|
||||
importBlendShapes: 1
|
||||
importCameras: 1
|
||||
importLights: 1
|
||||
fileIdsGeneration: 2
|
||||
swapUVChannels: 0
|
||||
generateSecondaryUV: 0
|
||||
useFileUnits: 1
|
||||
keepQuads: 0
|
||||
weldVertices: 1
|
||||
preserveHierarchy: 0
|
||||
skinWeightsMode: 0
|
||||
maxBonesPerVertex: 4
|
||||
minBoneWeight: 0.001
|
||||
meshOptimizationFlags: -1
|
||||
indexFormat: 0
|
||||
secondaryUVAngleDistortion: 8
|
||||
secondaryUVAreaDistortion: 15.000001
|
||||
secondaryUVHardAngle: 88
|
||||
secondaryUVPackMargin: 4
|
||||
useFileScale: 1
|
||||
tangentSpace:
|
||||
normalSmoothAngle: 60
|
||||
normalImportMode: 0
|
||||
tangentImportMode: 3
|
||||
normalCalculationMode: 4
|
||||
legacyComputeAllNormalsFromSmoothingGroupsWhenMeshHasBlendShapes: 0
|
||||
blendShapeNormalImportMode: 1
|
||||
normalSmoothingSource: 0
|
||||
referencedClips: []
|
||||
importAnimation: 1
|
||||
humanDescription:
|
||||
serializedVersion: 3
|
||||
human: []
|
||||
skeleton: []
|
||||
armTwist: 0.5
|
||||
foreArmTwist: 0.5
|
||||
upperLegTwist: 0.5
|
||||
legTwist: 0.5
|
||||
armStretch: 0.05
|
||||
legStretch: 0.05
|
||||
feetSpacing: 0
|
||||
globalScale: 1
|
||||
rootMotionBoneName:
|
||||
hasTranslationDoF: 0
|
||||
hasExtraRoot: 1
|
||||
skeletonHasParents: 1
|
||||
lastHumanDescriptionAvatarSource: {instanceID: 0}
|
||||
autoGenerateAvatarMappingIfUnspecified: 1
|
||||
animationType: 3
|
||||
humanoidOversampling: 1
|
||||
avatarSetup: 1
|
||||
additionalBone: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -7,7 +7,7 @@ AnimationClip:
|
|||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: "\u642C\u8FD01"
|
||||
serializedVersion: 7
|
||||
serializedVersion: 6
|
||||
m_Legacy: 0
|
||||
m_Compressed: 0
|
||||
m_UseHighQualityCurve: 1
|
||||
|
@ -20,7 +20,7 @@ AnimationClip:
|
|||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 5.05
|
||||
value: {x: -0.90787506, y: 4.417002, z: 1.11}
|
||||
value: {x: -0.90787506, y: 4.856, z: 1.11}
|
||||
inSlope: {x: 0, y: 0, z: 0}
|
||||
outSlope: {x: 0, y: 0, z: 0}
|
||||
tangentMode: 0
|
||||
|
@ -29,7 +29,7 @@ AnimationClip:
|
|||
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
|
||||
- serializedVersion: 3
|
||||
time: 5.6833334
|
||||
value: {x: -0.90787506, y: 4.417002, z: 0.62}
|
||||
value: {x: -0.90787506, y: 4.755, z: 0.628}
|
||||
inSlope: {x: 0, y: 0, z: 0}
|
||||
outSlope: {x: 0, y: 0, z: 0}
|
||||
tangentMode: 0
|
||||
|
@ -112,7 +112,7 @@ AnimationClip:
|
|||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 5.05
|
||||
value: 4.417002
|
||||
value: 4.856
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
|
@ -121,7 +121,7 @@ AnimationClip:
|
|||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 5.6833334
|
||||
value: 4.417002
|
||||
value: 4.755
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
|
@ -149,7 +149,7 @@ AnimationClip:
|
|||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 5.6833334
|
||||
value: 0.62
|
||||
value: 0.628
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
|
|
|
@ -1,5 +1,32 @@
|
|||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!1102 &-8587506749624615763
|
||||
AnimatorState:
|
||||
serializedVersion: 5
|
||||
m_ObjectHideFlags: 1
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: Animation2
|
||||
m_Speed: 1
|
||||
m_CycleOffset: 0
|
||||
m_Transitions: []
|
||||
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: 1827226128182048838, guid: d08c75570910bc847944604aa324b47e,
|
||||
type: 3}
|
||||
m_Tag:
|
||||
m_SpeedParameter:
|
||||
m_MirrorParameter:
|
||||
m_CycleOffsetParameter:
|
||||
m_TimeParameter:
|
||||
--- !u!91 &9100000
|
||||
AnimatorController:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -22,36 +49,14 @@ AnimatorController:
|
|||
m_IKPass: 0
|
||||
m_SyncedLayerAffectsTiming: 0
|
||||
m_Controller: {fileID: 9100000}
|
||||
--- !u!1101 &925524152759440563
|
||||
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: 1115122253037565728}
|
||||
m_Solo: 0
|
||||
m_Mute: 0
|
||||
m_IsExit: 0
|
||||
serializedVersion: 3
|
||||
m_TransitionDuration: 0.25
|
||||
m_TransitionOffset: 0
|
||||
m_ExitTime: 0.8026316
|
||||
m_HasExitTime: 1
|
||||
m_HasFixedDuration: 1
|
||||
m_InterruptionSource: 0
|
||||
m_OrderedInterruption: 1
|
||||
m_CanTransitionToSelf: 1
|
||||
--- !u!1102 &1115122253037565728
|
||||
--- !u!1102 &93773099344302657
|
||||
AnimatorState:
|
||||
serializedVersion: 6
|
||||
serializedVersion: 5
|
||||
m_ObjectHideFlags: 1
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: Take 001
|
||||
m_Name: Animation1
|
||||
m_Speed: 1
|
||||
m_CycleOffset: 0
|
||||
m_Transitions: []
|
||||
|
@ -64,34 +69,8 @@ AnimatorState:
|
|||
m_MirrorParameterActive: 0
|
||||
m_CycleOffsetParameterActive: 0
|
||||
m_TimeParameterActive: 0
|
||||
m_Motion: {fileID: 1827226128182048838, guid: d08c75570910bc847944604aa324b47e, type: 3}
|
||||
m_Tag:
|
||||
m_SpeedParameter:
|
||||
m_MirrorParameter:
|
||||
m_CycleOffsetParameter:
|
||||
m_TimeParameter:
|
||||
--- !u!1102 &3478173649101673336
|
||||
AnimatorState:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 1
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: mixamo_com
|
||||
m_Speed: 1
|
||||
m_CycleOffset: 0
|
||||
m_Transitions:
|
||||
- {fileID: 925524152759440563}
|
||||
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: -203655887218126122, guid: 3e27323a2ec4db9478ccb10e2035b941, type: 3}
|
||||
m_Motion: {fileID: 1827226128182048838, guid: 5f61108e3668b3d43a2feb79ce02afa5,
|
||||
type: 3}
|
||||
m_Tag:
|
||||
m_SpeedParameter:
|
||||
m_MirrorParameter:
|
||||
|
@ -99,7 +78,7 @@ AnimatorState:
|
|||
m_TimeParameter:
|
||||
--- !u!1107 &4812021731156076189
|
||||
AnimatorStateMachine:
|
||||
serializedVersion: 6
|
||||
serializedVersion: 5
|
||||
m_ObjectHideFlags: 1
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
|
@ -107,11 +86,11 @@ AnimatorStateMachine:
|
|||
m_Name: Base Layer
|
||||
m_ChildStates:
|
||||
- serializedVersion: 1
|
||||
m_State: {fileID: 3478173649101673336}
|
||||
m_Position: {x: 171.54893, y: 269.52444, z: 0}
|
||||
m_State: {fileID: 93773099344302657}
|
||||
m_Position: {x: 120, y: 320, z: 0}
|
||||
- serializedVersion: 1
|
||||
m_State: {fileID: 1115122253037565728}
|
||||
m_Position: {x: 286.25, y: 427.02444, z: 0}
|
||||
m_State: {fileID: -8587506749624615763}
|
||||
m_Position: {x: 360, y: 330, z: 0}
|
||||
m_ChildStateMachines: []
|
||||
m_AnyStateTransitions: []
|
||||
m_EntryTransitions: []
|
||||
|
@ -121,4 +100,4 @@ AnimatorStateMachine:
|
|||
m_EntryPosition: {x: 50, y: 120, z: 0}
|
||||
m_ExitPosition: {x: 480, y: 190, z: 0}
|
||||
m_ParentStateMachinePosition: {x: 800, y: 20, z: 0}
|
||||
m_DefaultState: {fileID: 3478173649101673336}
|
||||
m_DefaultState: {fileID: 93773099344302657}
|
||||
|
|
|
@ -0,0 +1,50 @@
|
|||
using UnityEngine;
|
||||
using System.Collections;
|
||||
|
||||
public class SetParentScript : MonoBehaviour
|
||||
{
|
||||
// Assign these in the Inspector
|
||||
public GameObject objectA; // The object you want to become a child and to lock/unlock
|
||||
public GameObject objectB; // The object to become the parent
|
||||
|
||||
private Rigidbody rbA; // Rigidbody of objectA
|
||||
|
||||
// Start is called before the first frame update
|
||||
void Start()
|
||||
{
|
||||
// Check if objectA has a Rigidbody component
|
||||
rbA = objectA.GetComponent<Rigidbody>();
|
||||
if (rbA == null)
|
||||
{
|
||||
// Log an error if no Rigidbody is found
|
||||
Debug.LogError("No Rigidbody found on objectA");
|
||||
return;
|
||||
}
|
||||
|
||||
// Lock the Rigidbody by setting constraints
|
||||
LockMotionAndRotation();
|
||||
|
||||
// Call the methods after 3 seconds
|
||||
Invoke("SetParent", 3f);
|
||||
Invoke("UnlockMotionAndRotation", 3f);
|
||||
}
|
||||
|
||||
// Method to set the new parent of the object
|
||||
void SetParent()
|
||||
{
|
||||
// Setting objectA as a child of objectB
|
||||
objectA.transform.SetParent(objectB.transform);
|
||||
}
|
||||
|
||||
void LockMotionAndRotation()
|
||||
{
|
||||
// Lock position and rotation by setting constraints
|
||||
rbA.constraints = RigidbodyConstraints.FreezePosition | RigidbodyConstraints.FreezeRotation;
|
||||
}
|
||||
|
||||
void UnlockMotionAndRotation()
|
||||
{
|
||||
// Unlock all constraints to allow movement and rotation again
|
||||
rbA.constraints = RigidbodyConstraints.None;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,11 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 24ad3742fe977824b94c7f5884e64fef
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -1 +1 @@
|
|||
{"m_ExpandedPrefabGameObjectFileIDs":[],"m_ExpandedSceneGameObjectInstanceIDs":[-617052,-485238,-55030,-48636,-48624,-48616,-36344,-36324,-36078,-33370,-22538,-22528,-15810,-14838,-14826,-14800,-14770,-14742,-14738,-14458,-14442,-14390,-12356,-12152,-12102,-12070,-11228,-11214,-11186,-11174,-11164,-11026,-10868,-10860,-10840,-4364,-1184,18736,24374,25064,25614,25658,29190,30052,33342,33522,36084,36192,36770,36816,37330,39684,40180,40264],"m_ScrollY":240.0,"m_LastClickedFileID":0,"m_LastClickedInstanceID":-10860}
|
||||
{"m_ExpandedPrefabGameObjectFileIDs":[],"m_ExpandedSceneGameObjectInstanceIDs":[-617052,-485238,-55030,-48636,-48624,-48616,-36344,-36324,-36078,-33370,-22538,-22528,-15810,-14838,-14826,-14800,-14770,-14742,-14738,-14458,-14442,-14362,-12356,-12310,-12152,-12102,-12090,-11228,-11214,-11186,-11174,-11164,-11026,-10868,-10860,-10840,-4364,-1184,18736,24988,25064,25614,25658,29190,30052,30948,33522,36084,36192,36770,36816,39684,40180,40264],"m_ScrollY":2791.0,"m_LastClickedFileID":0,"m_LastClickedInstanceID":33342}
|
|
@ -1 +1 @@
|
|||
{"cameraMode":{"drawMode":0,"name":"Shaded","section":"Shading Mode"},"sceneLighting":true,"audioPlay":false,"sceneViewState":{"showFog":true,"showMaterialUpdate":false,"showSkybox":true,"showFlares":true,"showImageEffects":true,"showParticleSystems":true},"in2DMode":false,"pivot":{"x":-3.297574758529663,"y":0.7839512825012207,"z":-39.852691650390628},"rotation":{"x":0.050744205713272098,"y":0.7208847999572754,"z":-0.05308065935969353,"w":0.6891537308692932},"size":1.586768627166748,"orthographic":false}
|
||||
{"cameraMode":{"drawMode":0,"name":"Shaded","section":"Shading Mode"},"sceneLighting":true,"audioPlay":false,"sceneViewState":{"showFog":true,"showMaterialUpdate":false,"showSkybox":true,"showFlares":true,"showImageEffects":true,"showParticleSystems":true},"in2DMode":false,"pivot":{"x":-0.11478721350431442,"y":-0.0320139080286026,"z":-35.37715148925781},"rotation":{"x":-0.1563953310251236,"y":-0.7768510580062866,"z":0.21249434351921082,"w":-0.5717731714248657},"size":3.0982770919799806,"orthographic":false}
|
Loading…
Reference in New Issue