Graphics

 View Only
  • 1.  Scripting Keyframes

    Posted 08-29-2019 03:46

    Help, I need...help!

    I've worked from an old script @bford helped me with several years ago to add keyframes from a text object.

    I think I've adapted it correctly, but can't get it to work.

    dim map as xpQuadObject
    dim posX as xpTextObject
    dim posY as xpTextObject
    dim posZ as xpTextObject
    dim MapZoom as xpAnimController

    self.GetObjectByName("map", map)
    self.GetObjectByName("posX", posX)
    self.GetObjectByName("posY", posY)
    self.GetObjectByName("posZ", posZ)
    self.GetAnimControllerByName("MapZoom", MapZoom)

    MapZoom.SetKeyFrameValue(map, 125, "position.X", CDbl(posX.text))
    MapZoom.SetKeyFrameValue(map, 125, "position.Y", CDbl(posY.text))
    MapZoom.SetKeyFrameValue(map, 125, "position.Z", CDbl(posZ.text))

     

    Any ideas what I have done wrong?

    Thanks,

    James.



  • 2.  RE: Scripting Keyframes

    Posted 09-09-2019 17:27

    Not sure if you figured this out yet but I think you need to add a MapZoom.Play line to your script.


    #XPression