CGTalk > Software > Autodesk 3ds max > 3dsMax SDK and MaxScript
Login register
reply share thread « Previous Thread | Next Thread »  
 
Thread Tools Search this Thread Display Modes
Old 04-15-2014, 04:36 AM   #1
Malkalypse
Jack of All Trades
 
Malkalypse's Avatar
Kevin Mackey
Arlington Hts, USA
 
Join Date: Nov 2005
Posts: 1,334
Send a message via MSN to Malkalypse
Move all keyframes forward?

What's the best way to move ALL the keyframes in a scene forward by (for example) one frame? Do I have to make a function to loop through every key of every track of every node, or is there some simpler way to accomplish this?

Either way, advice would be appreciated!
 
Old 04-15-2014, 06:27 AM   #2
spacefrog
Frog of the posts
 
spacefrog's Avatar
Josef Wienerroither
Freelance
Vienna, Austria
 
Join Date: Sep 2002
Posts: 2,458
According to the docs this should be easier. For example this should insert 40 frames at frame 0
Quote:
inserttime rootnode.children 0f 40f


I did not verify that this REALLY catches all controllers, but i would think so ...

See more here
http://docs.autodesk.com/3DSMAX/14/...C6ACCE-1358.htm
__________________

PowerPreview: High Quality Nitrous Previews for 3ds Max 2012|2013|2014

[ Free Download (ScriptSpot) ]

Home of The Frogs | Online Portfolio
 
Old 04-15-2014, 07:49 PM   #3
Malkalypse
Jack of All Trades
 
Malkalypse's Avatar
Kevin Mackey
Arlington Hts, USA
 
Join Date: Nov 2005
Posts: 1,334
Send a message via MSN to Malkalypse
Seems to work so far,thanks! I'll let you know if I encounter any problems
 
Old 04-15-2014, 08:27 PM   #4
denisT
MAX Doctor
 
denisT's Avatar
portfolio
Denis Trofimov
CA, USA
 
Join Date: Jul 2009
Posts: 9,638
Send a message via ICQ to denisT
Quote:
Originally Posted by spacefrog
According to the docs this should be easier. For example this should insert 40 frames at frame 0


I did not verify that this REALLY catches all controllers, but i would think so ...

See more here
http://docs.autodesk.com/3DSMAX/14/...C6ACCE-1358.htm

it moves keys of first root children only.
a little cleaner will be:
Code:
movekeys objects 10 -- or inserttime objects 0 10


but both these two methods don't work probably for global tracks, animatables stored ouside a pblock, and note tracks...

Last edited by denisT : 04-15-2014 at 08:32 PM.
 
Old 04-15-2014, 09:04 PM   #5
spacefrog
Frog of the posts
 
spacefrog's Avatar
Josef Wienerroither
Freelance
Vienna, Austria
 
Join Date: Sep 2002
Posts: 2,458
Quote:
Originally Posted by denisT
it moves keys of first root children only.
a little cleaner will be:
Code:
movekeys objects 10 -- or inserttime objects 0 10


but both these two methods don't work probably for global tracks, animatables stored ouside a pblock, and note tracks...


Thanks for the headsup - i thought the mxs docs meant all children, but it's text is quite ambiguous

Quote:
inserts time in all controllers of all children of...
__________________

PowerPreview: High Quality Nitrous Previews for 3ds Max 2012|2013|2014

[ Free Download (ScriptSpot) ]

Home of The Frogs | Online Portfolio
 
Old 04-15-2014, 10:52 PM   #6
denisT
MAX Doctor
 
denisT's Avatar
portfolio
Denis Trofimov
CA, USA
 
Join Date: Jul 2009
Posts: 9,638
Send a message via ICQ to denisT
Quote:
Originally Posted by spacefrog
Thanks for the headsup - i thought the mxs docs meant all children, but it's text is quite ambiguous

the rootnode children set is different than node children. it's all about 'map' ability. the rootnode children set is not recursively mappable.
 
reply share thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 12:35 AM.


Powered by vBulletin
Copyright ©2000 - 2016, Jelsoft Enterprises Ltd.