1. Help Center
  2. Getting Started
  3. Intermediate Series: Deeper Dive on Components

Scripts: Overview

An explanation of what scripts do

If the video is too small, mouse over the bottom right and click on the fullscreen icon after you hit play. 

max

About Scripts

Scripts are the building blocks of Motive-powered training scenarios. Scripts, when bundled with the media files and other assets they call on, are what gets sent to the headset or mobile device to make 3D scenes interactive. 

Scripts are comprised of several parts that work together to form a narrative.  Frames, Resources, Events, Conditions, and Variables are all parts of a script.  

All scenarios typically start with a Director Script. This is the script that will be launched when the scenario begins in VR. The Director Script is meant to control the flow of the scenario. Note that Director Scripts are not mandatory, it's simply a best practice for organizing your content.

As you create your scenario, you may have several or many individual scripts - but they all link back to the original Director Script.  In my example, I’ve created four:

All scripts

Each of my four scripts does different things.  The "Launch Welcome Message" puts a message to the learner on the wall.  The "Ambience" script directs music to come out of a speaker.  The "Video Content" script plays a video for the learner.  The "Launch Equip Hard Hat" allows the learner to interact with a hard hat in the scene, pick it up, and put it on her head.  

When they all come together in the Director Script, I have a flowing scenario.

Create

There are two common ways:

Within the Scenarios tab, choose Add New Script:

add new script

Or, anywhere in Storyflow, you can click on the Scripts icon on the far right.  From there choose the Script heading and then Add New Script.

add new script 2

Edit

To change the name of the script, simply click on the name and make your change.  To change other elements of the script just choose the option you want to change and make a different selection or deletion.

Flow

As your scenario runs, the scripts will play unless you've specified conditions that would cause one script to run before the next.  This action is called end script or close script.  For example, when a learner enters my scenario I want them to see a Welcome Message on the wall.  Once they've read it and clicked "close", then a video plays.  If I don't end the script for the Welcome Message then BOTH will play simultaneously and the learner will see a Welcome Message at the same time that a video starts playing.  We handle this situation with Conditions.

Welcome Message

End script resource

Launch Video

Therefore, it's suggested that you always end a script before moving to the next.  That way if you need to add any conditions, it is much easier than going backward.  

Two important topics related to this are Framing and Branching.  Please see those articles for more detailed information.