Forgot password?

Create an account!


« back

RhinoScript – Automate the SetPathAnimation Command from Rhinoscript


Please log in to write a message.

  • 5. trojax (Nov 03, 2009 14.37):

    Yes! It helps very much!
    Big thank you!

  • 4. Hanno (Nov 03, 2009 11.49):

    selid is a command that allows you to select an object by entering its id. And because you are dealing with object ids in RhinoScript and need to select objects when working with commands, you can use this command to select your objects.
    Another useful command is enter, which does exactly what it says - pressing enter.
    So if you want to move two objects, you can do it like this:

    rhino.command "_move _selid " & myObject1 & " _selid " & myObject2 & " _enter 0,0,0 0,0,100"

    (although in this case I would strongly suggest to use rhino.move :-)

    Hope that helps!


  • 3. trojax (Nov 02, 2009 16.46):

    Thanks a lot!
    Can you give me a small example of how to use _selid?

  • 2. Hanno (Nov 02, 2009 16.07):

    With Rhino.Command you always must

    (1) use "_selid" if you want to use object ids

    (2) put spaces between your values. If you make a string like

    "100" & "200"

    the result will be "100200"

    Hope that helps!


  • 1. trojax (Nov 02, 2009 15.53):

    Hi everybody,

    I just don't know how to automate te SetPathAnimation Command from Rhinoscript.
    My Code should search a curve or point named " Camerapath" and a curve or point named "Targetpath". It should get the identifiers of both and should do the SetPathAnimation Command with all parameters specified in the code below.
    But Rhino doesn't take the identifiers of the curves and is still saying "Pick a Curce or Point" in the Commandline.
    How do I get Rhino to take my instructions from Rhinoscript or, if this is all correct- How does Rhino the Cameracure and Targetcurve definitions to be so that it doesn't long for user input.

    I have a Toolbarbutton in which i directly postet:

    ! _-Runscript (
    Dim arrObjects, arrObjects2 , strCamerapath, strTargetpath
    strCamerapath = "Camerapath"
    strTargetpath = "Targetpath"
    arrObjects = Rhino.ObjectsByName(strCamerapath, True)
    arrObjects2 = Rhino.ObjectsByName(strTargetpath, True)

    Dim cmd : cmd = "_-SetPathAnimation " & arrObjects(0) & arrObjects2(0) & "100" & "j" & "R" & "Name_of_my_view" & "Animation"

    Rhino.Command cmd

    Can anyone help me please?
    I'm lost!


Why are these buttons gray?