Notifications
Clear all

[Closed] How do I change the time configuration using MaxScript?

I’m reading an excel file and it changes the keys needed to develop the scene. Problem is if I don’t have the time width long enough it screws everything up. I was hoping to program in a way that it will read the end time and adjust the time span accordingly.

2 Replies

Hi Joe,
I understand you need to adjust current number of animation frames. Take a look at “Time Configuration Dialog” in MaxScript Reference:

-- Example taken from reference

-- Get the current animation range
animationRange
(interval 0f 100f)

-- Set range to frames 10 to 50
animationRange = interval 10 50
(interval 10f 50f)

-- Get the start frame of the range
animationRange.start
10f

-- Get the end frame of the range
animationRange.end
50f

-- To change the end frame of the interval only:
animationRange = interval animationRange.start 90f
(interval 10f 90f)

  • Enrico

Thanks it works great.