mcjRepeatAction: repeat actions over a range of frames
https://sites.google.com/site/mcasualsdazscripts4/mcjrepeataction
this script will perform actions repeatedly over a specified time range
ex: you select a ball, you specify that the action is "Drop to Floor" ( CTRL-D ),
you specify you want this to be applied over the playRange ( which happens to be frames 0 to 30 )
and the script goes frame by frame and activates the drop to floor action
the following standard Daz Studio built-in actions are supported
DzRestoreFigureAction
DzRestoreFigurePoseAction
DzRestoreFigureMorphsAction
DzRestoreSelectedItemsAction
DzRestoreTransformsAction
DzMoveToFloorAction
DzAddKeysAction
DzDeleteKeysAction
when 2 nodes are selected
You can specify which of the nodes to treat as the 'Target'
and the following actions ( by me ) are available
Move Below Target
Move Above Target
World Pos Like Target
World Rot Like Target
World Scale Like Target
Local Pos Like Target
Local Rot Like Target
Local Scale Like Target
Lets say you want a figure to pick a sword then later leave it somewhere
you animate the part of the movie where the figure wields the sword - the sword is parented to the figure's hand
you create a null node and use the script to have the Null node follow the position and orientation of the sword
for the frames where the wielding occurs
then you unparent the sword from the figure's hand
and you use the script to make the sword follow the position and orientation of the Null node for the frames where the wielding occurs
i once used that method to get an Alice to pick up a bottle of "Drink Me" , and ... well it can still be tricky but it can be done !
Comments
Oh looking forward to this one. You never cease to amaze ;-)
when only 1 node is selected
the unusable actions ( which require 2 nodes ) are hidden
-------
while i'm at it i'll add an action to delete only the morph keyframes and one to delete only the transform keyframes
because sometimes when animating head movements
you want to clear all animated head movement keyframes
but you don't want to destroy all the face morph settings/animations
also sometimes you want to keyframe ( i call this pinning down )
the head movements ) without disturbing the lipsync and blinkings
maybe i could use Daz Studio's DzAddKeysAction and DzDeleteKeysAction but lock or unlock the transforms before activating them?
( morphs got complicated with DS4.5 they are dangling off the root of the figure )
quirk: for now, the script works for frame-exact keyframes but not for inter-frame keyframes .. which are often created by MiMic
i often use mcjDecimate for the "pinning down" tasks
soon !
i just want to make sure it works for DS1, DS2
did tests with DS3, DS4.6 and it all seems to work
---
Fig 1 - Amy breaking the 4th wall, in DS4.6
Fig 2 - Logos for the 2 versions
Fig 3 - DS 2.3, deleting and setting keyframes on morphs without disturbing motion animation
Fig 4 - DS 2.3 the animation
Fig 5 - DS 1.8 compatibility ( did require a little tweak action,activate() instead of action.toggle() )
doing a few tests helps get you a better script
for instance this test revealed the need to display figure names
else we had no way of differentiating/selecting the "Target"
ready ! ( except the manual is thin )
https://sites.google.com/site/mcasualsdazscripts4/mcjrepeataction
Downloaded :-)
off to play now and see if I can make it work too :-)
Okay ... waiting for the more complete manual. Drop to floor works real good. Never comes back up, but it sure it sure fell down .... presumably I missed in the steps.
i
say you specify you want frames 10 to 20 to get the "drop to floor " action
it's the same as if you
moved the timeline to frame 10, clicked cttl-d (drop to floor )
moved the timeline to frame 11, clicked cttl-d (drop to floor )
.
.
.
moved the timeline to frame 20, clicked cttl-d (drop to floor )
so if there was no key-frame to keep the object up in the air past frame 20, there isn't one now either and the object remains of the floor til the end of time(line)s
so you could apply the "add transform keys" action on frame 0 to 30, to "pin down" the current animation, then use the "drop to floor" action on frames 10 to 20
improved the manual a little
learn to do this stupid puck trick !
https://sites.google.com/site/mcasualsdazscripts4/mcjrepeataction
Thank you, downloaded will have some more fun later ;-)