In this page, you will find instructions for how to install all essential tools and run your first Grasshopper-C# script

No worries we will go through these steps at our first meeting!


Prerequisite

1. A desktop / laptop with Windows or MacOS

2. A mouse is highly recommended (Apple Magic Mouse is not recommended)

3. MIT Wi-Fi or MIT VPN, or other sources of Rhino license

4. A Rhino account


Installation

Rhino

Rhino 8 provides a 90-day trial. Please select correponding "One-Time Evaluation" version on the official download page.

Rhino 7 doesn't have trial version. MIT STOA provides free Rhino 7 and 8 license for current students. Please follow installation instructions under "CAD" tab of STOA Application page. STOA educational license only works when connected to MIT Wifi or MIT VPN.

NOTE: We use Rhino 7 to compose materials of this course, while there shouldn't be significant difference between 7 and 8 in terms of the content we will cover.

After opening Rhino and select any template for Windows or "new model" for MacOS, you should see one of the interface below depend on your system:

Interface of Rhino for Windows

Interface of Rhino for MacOS

Grasshopper

At Rhino Interface, directly type "grasshopper" and press enter, you should see Grasshopper's interface popping up:

NOTE: Grasshopper's window is always on top of Rhino's window. Resize or minimuze it to reveal Rhino interface.

Interface of Grasshopper

Recommend tools for coding in Grasshopper

Since Grasshopper's coding interface lacks good user experience, we highly recommend you to install Script Parasite and write code in Visual Studio Code.

ScriptParasite

ScriptParasite is a Grasshopper plugin that synchronize the code inside a Grasshopper C# component with a local file.

Step 1: Download and unpack the plugin files forRhino 8 (both systems) or Rhino 7 Windows or Rhino 7 MacOS. You should see one .gha file and one .pdb file (For Rhino 8 there's only .gha file).

Step 2: Open Grasshopper's components folder. In menu bar, choose File > Special Folders > Components Folder, a folder named Libraries should pop up.

Step 3: Drop the .gha file and .pdb file into the Libraries folder. Restart Rhino and Grasshopper.

Step 4: In Grasshopper Interface, press SPACE, type "scriptparasite", and press ENTER, you should be able to drop a ScriptParasite component on the canvas like below:

A ScriptParasite component dropped on Grasshopper canvas

Visual Studio Code

Visual Studio Code (VSC) is a popular and convenient code editor. Download and install it here.

You can also use other code editors like Sublime Text or IntelliJ IDEA as long as it correctly highlights C# code.

It is recommended that you create a folder for scripts in this class. Directly drag the folder into VSC to open it, and you will be able to view and edit all scripts in the folder like below:

A Visual Studio Code interface with a folder open (left panel) and a script displayed


Test your installation with a given script

If you feel everything above goes well for you, you can test your installation and have a taste of Grasshopper with this hello world script!

What you are expected to see when directly open the script

There are a few more steps inside the script. Before start, copy the path to the folder you hope to store your scripts. For Windows: click the address bar of file explorer and copy it. For MacOS: right click the folder, hold OPTION key, and choose "copy xxx as Pathname".

Try to finish the steps and you are all done!

All the steps finished