Jump to content

Kyle Dorosz

Regular Member
  • Content Count

    1
  • Joined

  • Last visited

Community Reputation

0 Noble Beginner

Profile Information

  • First Name
    Kyle
  • Last Name
    Dorosz

Cinema 4D Information

  • C4D Version
    R20.026 Studio
  1. Hello, I am working on a script that will pull information from individual frames in an animation. I am having a problem and narrowed it down to the FOR loop that is used to run through the frames of the animation. Can anyone help to identify why the following code will only set the current frame to the last value in the FOR loop? The goal is to run the script and get the "Frame" and "Value F" to display the same number. import c4d from c4d import gui def main(): fps = doc.GetFps() #get fps number bt=doc.GetTime() obj = doc.SearchObject("Cube") for f in range(0, 96, 24): doc.SetTime(c4d.BaseTime(f, fps)) c4d.EventAdd() print "Object =", obj print "Frame = ", bt.GetFrame(fps) print "Value F = ", f if __name__=='__main__': main() Any help is greatly appreciated! Thank you, Kyle
×
×
  • Create New...