This tool can be used to record a complex hierarchy of GameObject's child transforms (during editor or runtime) in a ScriptableObject. This allows you to pose the character around your scene, take marketing screenshots, or anything similar.
More motivations and implementation details can be found at my blog
TransformsRecorder can be installed via OpenUPM. It's recommended to install it via openupm-cli:
openupm add com.mezookan.transforms-recorder
You can add the package to your project as a git upm dependency.
Either add the following line to your project's Packages/manifest.json
file's dependencies:
"com.mezookan.transforms-recorder":"https://github.com/abbabon/TransformsRecorder.git?path=Packages/TransformsRecorder",
or via the Windows/PackageManager
menu, by adding the following git repo: https://github.com/abbabon/TransformsRecorder.git?path=Packages/TransformsRecorder
- Place the 'TransformRecorder' script on any object in your scene.
- Drag the parent of the transform hierarchy you wish to record to the 'Parent Transform' field.
- Create a scriptable object from TransformDataContainer by right clicking on you project window, and then
Create->ScriptableObjects->TransformDataContainer
- Drag the new TransformDataContainer to the TransformRecorder's relevant field.
You can now save the transform hierarchy by pressing the 'Record Transforms' button, or load with 'Load Transforms'. Just remember to create a scriptable object for each pose / sate. I encourage you to experiment further and expand the system.
An example scene is setup in the repo (not in the package), so you can see it in action.
Free to use under the MIT License
'The Boss' Model and animations supplied by Adobe (taken from Mixamo.com).