Finding First Key
I'm trying to find the keyframe of the first key for a selection of objects.
This is what I have so far and it's chucking up a few errors.
Figured I would get some other eyes on this.
if selection.count >= 1 then ( for i=1 to selection.count do ( obj = selection[i] if obj.controller != undefined and obj.isAnimated then ( getKeyTime obj.controller 1 ) ) )
Comments
Modifier Extrude Amount Keys
Hi i cant make 3dsmax to return the keys on a extrude modifier, how can i do it?
i get keys from position, rotation an scale only?
Thanks
Modifier
So if both of those scripts find the first key on the transform how do I find the first key on any modifier that could possibly be on the object? Or even the first key on a light multiplier for instance.
John Martini
Digital Artist
http://www.JokerMartini.com (new site)
Well, just define what you
Well, just define what you want to gather. Looks like you need a function that collect all controllers for the base object transform + it properties + all properties of all modifiers on it ... well, no easy way. 1st need to get all props (see
getPropNames
mxs function), then check if they has controller, then check if it has keys ...my recent MAXScripts RSS (archive here)
Hi John, obj.isAnimated not
Hi John,
obj.isAnimated
not helps here,need to test if the controller has keys:
obj.controller.keys.count -- or numKeys obj.controller
if no keys, both will return -1 ,
and the expression may become...
but that still useless 'cause the
obj.controller
is the transform controller and there no keyable tm-controllers. Next snippet will collect 1st key-time for position controller -my recent MAXScripts RSS (archive here)