Adding Scripts to an Object
Last updated
Last updated
You can add scripts to objects in order to make them perform actions or interact with avatars and the environment. When scripts are added to an object, they become part of the object as that object's component. Currently, there are two ways to add a script component to an object:
To add scripts using the drag and drop method from your Inventory:
In Edit Mode, choose an object you want to apply the script to. It can be an existing object in the scene or a new object from your Inventory. If you wish to add the script to a new object, drag that object into the scene.
Select the script from your Inventory and drag the script to the object.
Now that the script has been applied to the object, open the properties panel for the object. Select the object and click the Properties button to open the properties panel.
At the bottom of the object's Properties panel is a Script Settings section. From there, you can edit the script's parameters.
To add scripts via the Scene Objects panel, see adding scripts in Object Editing.
For more information on scripts, see Working with scripts.
Click the Properties button on the object menu.
Drag and drop a script onto an object in the scene.