Running And Debugging Scripts
Script Location
When you start working on your script, you want to keep it on your own computer(s), rather than publish it for all ARDI users to see.
ARDI provides a directory to keep all of your scripts (and any associated media files, such as voiceovers, images and videos).
It's located in your Documents folder. You should find a folder named Optrix/ARDI/<database-name>Scripts (for example, if your database is called “Headquarters”, it would be under Optrix/ARDI/Headquarters/Scripts)
Create your script file in this folder. You can use the extension 'xml' or 'script' (calling your file 'script' will save you an extra step later, when you publish).
We also suggest creating a folder with the same name as your script (without the file extension), to hold your media.
So if you were making a script called Introduction on a server called Headquarters, you'd create…
Optrix/ARDI/Headquarters/Scripts/Introduction.xml (your script file)
Optrix/ARDI/Headquarters/Scripts/Introduction (your media folder)
See Supported Script Media Formats to know what type of files to use.
Running Your Locally-Saved Script
- Run ARDI-VE and connect to your server.
- Press F11
- Press Run Local Script
- Choose the script you want to run.
Using the Script Editor
Optrix offers a Windows-based script editor application. This connects directly to your ARDI instance and allows you to browse through the objects inside your scene and test your script - or individual lines in your script - directly.
Please contact Optrix if you would like a copy of the application.
Referencing Media
If you want to use a media file in your script, remember to include the script name in the path so that the system can find your media files.
So if you wanted to include a voiceover file - hello.ogg - in your script, you'd place the file in Optrix/ARDI/Headquarters/Scripts/Introduction/hello.ogg and you'd call it in your script with…
<voiceover name="Introduction/hello.ogg"/>
Deploying
Once you've polished your script and have it ready for your audience, you can deploy it to your server.
See the Deploying Scripts to your Server article.