Export transform of melee weapon in hand as an animation?
Hi,
I'm trying to make a simple first person game and I don't want visible arms but just a melee weapon in the camera view. I tried animating a 'swing' animation for the weapon but it doesn't look good. I have some motion capture animations of melee weapons being swung but I just want the transform position and rotation exporting in an animation for my weapon to move, so it looks natural? Maybe if I added an object to the hand bone of the animation, I could export that objects movement?
Is this possible? Thanks
Answer
Hi,
thank you very much for your support request.
The following could work:
- Create a script that copies the world space position/rotation of one transform to another (each frame). You can use this script to copy the mocap weapon transform to your weapon (that is not parented to anything).
- Then use Unity's animation recorder package to record that animation (you can get this via the package manager).
Another method (that would result in less key frames):
By using the "Sync" button in UMotion, you are able to synchronize the frame cursor of Unity's Animation Window (or Unity Timeline) with UMotion's frame cursor. So you could play the mocap animation using a Unity window, and use it as a reference to animate your first person melee weapon in UMotion. More information regarding the "Sync" feature can be found in the manual chapter "Unity Timeline Integration".
Please let me know in case you have any follow-up questions.
Best regards,
Peter
Customer support service by UserEcho
Hi,
thank you very much for your support request.
The following could work:
Another method (that would result in less key frames):
By using the "Sync" button in UMotion, you are able to synchronize the frame cursor of Unity's Animation Window (or Unity Timeline) with UMotion's frame cursor. So you could play the mocap animation using a Unity window, and use it as a reference to animate your first person melee weapon in UMotion. More information regarding the "Sync" feature can be found in the manual chapter "Unity Timeline Integration".
Please let me know in case you have any follow-up questions.
Best regards,
Peter