Scripting
In Grid Studio, all of the scripting has been switched to be in fully Python. This enables a more versatile and easier approach to scripting environment.

This means that all of the standard python functions are fully supported.
If there are some additional functions that you like to help with what you want to do, you can extend the functionalities by importing some additional libraries.

For some users, scripting in a proper IDE is a more preferred option. In Grid, it is possible to link Visual Studio Code with Grid Studio.
To do so, you would need to go under the Preferences section and under the Script Settings tab, you would provide the path to where Visual Studio Code is intalled on your local machine. This is typically located at C:/Users/[user_name]/AppData/Local/Programs/Microsoft VS Code/Code.exe

Once this is done, then in any scripting object, you would find the VS Code icon at the top right corner to edit your script inside VS Code.

A temp file would be created and linked to the script object in your project. You can then directly edit inside VS Code and save that file, and see the changes are updated inside the corresponding script object in your project.

Some Custom SP Functions
Working with Color values
brighter()
returns a color that is brighter
amount=float
contrast()
returns a color with a certain amount of contrast
int
darker()
returns a color that is darker
amount=float
interpolatedWith()
spColor, float
isBright()
returns a bool if the color is a bright color
isDark()
returns a bool if the color is a dark color
overlaidWith()
sp.Color
withAlpha()
returns a color with a specific alpha value
int
Last updated