4.4. RhinoScriptSyntax

RhinoScriptSyntax in GH-Python

RhinoScriptSyntax contains only Functions, not Classes or Structures. This functions send instructions to Rhino to perform some action. In this case we do not need to create objects in Python, we just run functions to create and change objects.

The keyword import allows us to import this module into our script.


# import rhinoscriptsyntax library
import rhinoscriptsyntax as rs

Vertices

Rhino can access the RhinoScriptSyntax library and run commands, which will then create the object in Rhino, but it will only perfom an action and return a GUID (Global Unique IDentifier)

Vertices

# Import rhinoscriptsyntax library
import rhinoscriptsyntax as rs
# Add a Point from rhinoscriptsyntax
pt = rs.AddPoint((1,2,3))
print pt # It will return a GUID