Skip to main content
Version: 4.6.0

Make Your First Effect With Visual Scripting

Make Your First Effect With Visual Scripting

Try making a simple effect by using the Mouth open and Mouth close actions to change the visibility of a cube. You can also follow along in the sections below. Here is a demo of the final result and the project package:

effect final result

↓ visual_scripting_demo.zip

Add an Object and Nodes

  1. To start, add a 3D cube object to the scene by clicking the Add button [+].
  2. Go to 3D and click Cube. Adjust the Position parameters of the cube to place it in the desired position on your screen.
add cube object
  1. Since you are using mouth open/close actions as triggers, select a Mouth Open demonstration video from the drop-down list in the Preview panel to test the effect.
select mouth open
  1. Right click in the Visual Scripting panel, and search for and select the Facial Movement Detection. Set the Facial Movement property to Mouth Open.
facial movement detection

45

set visibility node
  1. In the node information, check the required inputs. Since Set Visibility needs to take an Object, select the cube object from the Hierarchy panel and drag it to the Visual Scripting panel. This will create the cube object node automatically.
drag to panel
  1. Set the visibility value. There is a checkbox next to the Value of Visibility On. Select or deselect it to set the value to true (visible) or false (invisible), respectively.
set value
  1. Link the Begin output of Facial Movement Detection to the Enter input of Set Visibility, link the Entity output of Cube to the Target input of Set Visibility, and then deselect the checkbox next to the Visibility On input of Set Visibility.
set value
  1. Add a new Set Visibility node in order to make the cube visible when the mouth is closed. Link the newly added nodes accordingly and select the Visibility On checkbox this time. You can move the nodes around to clean up and organize your interface.
set value
  1. Congratulations! Now that you’ve learned the basics of visual scripting, feel free to incorporate it into your own effects.