기타/Unity
Rigidbody 이동을 애니메이션 클립으로 만들기
푸쿠이
2022. 6. 24. 17:31
어떤 오브젝트에 부딪혔을 때, 분리되면서 툭툭 굴러 떨어지는 느낌을 줘야하는 연출이 있었다.
직접 물리로 굴러 떨어트려도 되지만, 이러한 물리 이동을 애니메이션 클립으로 만드는 법이 있었다.
https://docs.unity3d.com/2020.1/Documentation/ScriptReference/Animations.GameObjectRecorder.html
Unity - Scripting API: GameObjectRecorder
This class binds GameObject properties, records their values as they change in the running Scene, and saves the result in an AnimationClip. The recorded GameObject is called root in the class, and you can also bind the properties of any child of root. See
docs.unity3d.com