Graphics

 View Only
  • 1.  Beginner XPression Scripting Question - Take ID

    Posted 04-23-2013 19:37
    I have no prior experience with VBScript and some very limited previous programming experience, never really put it to any practical use before. Looking forward to playing with scripting in Xpression and seeing what I can do.

    I'm trying to do something very basic and can't seem to figure out and there aren't many resources for me to refer to. I've looked at the XPression API documentation, but it really doesn't help me out as a beginner.

    Anyways, I would like to have a certain "Take ID" in my sequencer start playing when I take a particular scene.

    I was trying to use xpBaseTakeItem and GetTakeItemByID and then .execute.... But not getting any results.

    Also, can anyone out there point me in the right direction of getting comfortable in scripting with vbscript along with how I'd apply it to XPression. Any decent online tutorials out there?


  • 2.  RE: Beginner XPression Scripting Question - Take ID

    Posted 04-25-2013 10:03
    Where do you write your code ? Can you copy here your code to see what you do ? Thank you.

    #XPression


  • 3.  RE: Beginner XPression Scripting Question - Take ID

    Posted 04-25-2013 14:48
    What I'm trying to do is have my bug trigger when I hit the open. This works fine for most of our shows:

    I wrote the code in the OnOnline section.

    dim bug As xpScene

    Engine.getSceneByName("7Bug", bug)

    bug.SetOnline(0, 10)

    BUT our morning show has an animated bug with time/temp and the above code applied to the time/temp will not animate the scene. If possible, I'd just like to trigger the ID# from our "Persistent Graphics" section on our sequencer. I'm really at a loss of what to do next, I've tried different variations of code that I've come across in the help file, but as I said, I really don't know what I'm doing.

    I'm planning on spending some time just learning vbscript so I have a better grasp of the language overall and hopefully that would help. Seems like it should be pretty simple, I'm swinging in the dark right now though.

    #XPression


  • 4.  RE: Beginner XPression Scripting Question - Take ID

    Posted 04-25-2013 16:57
    After bug.setonline, do a bug.scenedirector.play()

    #XPression


  • 5.  RE: Beginner XPression Scripting Question - Take ID

    Posted 04-25-2013 17:57
    Thanks Vincent! You rock! Works like a charm!

    #XPression


  • 6.  RE: Beginner XPression Scripting Question - Take ID

    Posted 04-25-2013 18:08
    You're welcome...

    #XPression


  • 7.  RE: Beginner XPression Scripting Question - Take ID

    Posted 04-30-2013 18:09
    Just realized that this solution doesn't work for me. I need to take the ID from the sequencer because that's where I'm updating the temperature values during our show. Taking the scene directly will not have my updated temps....

    Let's say the ID # in my sequencer that I need to take is 9005. Ideas?

    #XPression


  • 8.  RE: Beginner XPression Scripting Question - Take ID

    Posted 05-01-2013 09:54
    Dim MySequencer as xpSequencer = nothing

    MySequencer = Engine.Sequencer

    Dim MyTakeItem as xpTakeItem = nothing

    MySequencer.GetTakeItemByID(9005, MyTakeItem)

    MyTakeItem.Execute()


    #XPression