How to Use the Script Function
Updated: 06/14/2024
Click here for information for developers.
Script types
Application script | Model script |
---|---|
Scripts to run throughout the application | Scripts to run for each model |
Multiple registrations possible | Multiple registrations possible |
Put the .js file in the scripts folder where the .ini file and models are stored. | Put the .js file in the scripts folder at the Model location (usually the model3.json location). |
Initially OFF | Initially OFF |
How to use
1. Click the Settings/Other -> Scripts (beta).
2. When the Script Manager starts, press the Open folder button in the lower-right corner of the screen.
3. Press Open folder in scripts/. Write the following text in a file named hello.js, place this file in the scripts folder, and then restart.
console.log("hello")
4. Turn on the Enable scripts toggle and individual file toggles (these toggles are initially disabled).
Once the script has run, open the log window with the button in the lower-left corner of the screen to see the logs executed by the script.
Point
Clicking the Create button will automatically create the above sample script.
Point
Open the folder at the model icon to open the model script folder. The .js in it is registered when the model is loaded.