realvirtual.io
  • Building Digital Twins with Unity and realvirtual.io
  • Basics
    • Installation
    • Demo Model
      • Old Demo Model
    • Editor User Interface
      • Hierarchy Window
      • 3D Views
      • Quick Edit
      • Move Pivot Points (Pro)
      • Selection Window (Pro)
      • Material Window (Pro)
      • Measurement (Pro)
      • Kinematic Tool (Pro)
      • Model Checker
    • Runtime UI
      • Group Manager
      • Debug Console
      • Responsiveness
      • Runtime Persistence
    • Importing and exporting
    • Folder structure
    • Tutorial
    • Physics
    • CAD import (Pro)
      • CADLink (Pro)
      • CAD Checker (Pro)
      • CAD Updater (Pro)
    • Reusable Components (Prefabs)
    • Cadenas parts4cad
    • Publishing the Digital Twin
    • Revision management
  • News
  • Login & Download Updates (Pro)
  • Components & Scripts
    • Realvirtual
      • Environment Controller
    • MU, Source and Sink
      • Source
      • Sink
    • Motion and Kinematic
      • Drive
      • Kinematic
      • Group
      • Joint
      • CAM
      • TransportSurface
      • Guided Transport
      • Drive behavior
      • Chain
      • Chain element
      • Motion for developers
    • Sensors
      • Sensor
      • Measure
      • MeasureRaycast
    • Picking and Placing MUs
      • Grip
      • Gripper
      • Fixer
      • Pattern
    • Changing MUs
      • MaterialChanger
      • PartChanger
      • Cutter
    • Scene Interaction
      • 3D Buttons
      • Screen Overlay Buttons
      • Scene Selectables
      • Lamp
      • Interact3D
      • UI components
      • HMI components (Pro)
        • Start your own HMI
        • HMI Tab
        • HMI DropDown
        • HMI Puschbutton
        • HMI Switch
        • HMI Value
        • HMI Text
        • HMI Slider
        • HMI Message
        • HMI Marker
      • ModelZoo (Pro)
    • Interfaces
      • Interface Tools
        • Signal Manager
        • Signal Importer Exporter
        • Signal Catcher
        • OnValueChangedReconnect
      • Signal Importer / Exporter
      • ABB RobotStudio (Pro)
      • Denso Robotics (Pro)
      • EthernetIP (Pro)
      • Fanuc (Pro)
      • FMI
      • Igus Rebel
      • MQTT (Pro)
      • Modbus (Pro)
      • OPCUA (Pro)
      • PLCSIM Advanced (Pro)
      • RoboDK (Pro)
      • RFSuite (Pro)
      • SEW SimInterface (Pro)
      • Siemens Simit Interface (Pro)
      • Simit Shared Memory (Pro)
      • Simulink (Pro)
      • S7 TCP
      • TwinCAT (Pro)
      • TwinCAT HMI (Pro)
      • UDP (Pro)
      • Universal Robots (Pro)
      • Wandelbots Nova (Pro)
      • Websocket (Pro)
      • Windmod Y200 (Pro)
      • Custom Interfaces
    • Performance Tools
      • Combine Meshes (Pro)
      • Create Prefab (Pro)
      • Hierarchy Cleanup (Pro)
      • Mesh Optimizer (Pro)
      • Performance Optimizer (Pro)
    • Defining Logic
      • Unity Scripting
      • Behavior Graph
      • Logicsteps
      • Unity Visual Scripting
      • Recorder
    • Robot Inverse Kinematics (Pro)
    • Volume Tracking (Pro)
  • Multiplayer (Pro)
  • Extensions
    • ModelZoo
      • Beckhoff TwinCAT
      • Siemens S7
      • Denso Cobotta 1300
      • Wandelbots Nova Fanuc CRX
      • Universal Robots UR10
      • Fanuc Roboguide
    • realvirtual.io AIBuilder
      • realvirtual.io AI Builder Overview
      • Generate AI Training Data
      • AI Training
      • Testing AI in a Digital Twin
      • Deploying the AI
    • realvirtual.io Simulation
      • Conveyor Library
      • Path System
        • Path finding
        • Line
        • Curve
        • Workstation
        • Catcher
        • Pathmover
    • realvirtual.io Industrial Metaverse
      • Setup Guide
      • VR Modules
      • AR Modules
      • Multiuser
    • AGX Physics
    • VR Builder
    • CMC ViewR
  • Advanced Topics
    • Render Pipelines
    • Mixed Reality with Meta Quest3
    • Upgrade Guide
      • Upgrade to 2022
    • Open Digital Twin Interface
    • Usefull Addons
    • Improving Performance
    • Supported Platforms
    • Compiler Defines
    • For Developers
      • Important Classes and Interfaces
      • Assembly Definitions
      • Starting your development
      • Class documentation
      • realvirtual Init Sequence
      • realvirtualBehavior Lifetime Methods
      • Testing
    • Newtonsoft JSON
    • Troubleshooting
  • Release Notes
  • AI Digital Twin Assistant (GPT4)
  • License Conditions
Powered by GitBook
On this page
  • Installation
  • realvirtual.io nodes
  • Building your own nodes
Edit on GitHub
  1. Components & Scripts
  2. Defining Logic

Unity Visual Scripting

PreviousLogicstepsNextRecorder

Last updated 6 months ago

Starting with Unity6 and realvirtual 6 we removed Visual Scripting. It is replaced by Unity Behavior Graph.

Starting with realvirtual.io Professional 2021, we have added support for Unity Visual Scripting.

You can find out more about Unity Visual Scripting here in the Unity documentation .

Unity’s Visual Scripting is a visual approach to programming. You can even track the status of the script during simulation. However, compared to the realvirtual.io LogicSteps alternative and to Playmaker, Unity Visual Scritping is less “step chain” oriented.

Installation

Unity Visual Scripting is an optional package and must be installed via the Unity Package Manager. You can search for “Visual Scripting” and you will find the latest package. Press “Install” to install the package.

After Unity Visual Scripting is installed you need to set the compiler define. Please go to "Edit > ProjectSettings > Player > Other Settings". There you will find a section "Script Compilation - Scripting Define Symbols". Please add there "REALVIRTUAL_VISUALSCRIPTING"

Now you will need to regenerate the visual scripting nodes by going to "Edit > ProjectSettings > VisualScripting". Please select "Regenerate Nodes"

After you regenerated the Nodes also the realvirtual.io Nodes are available and you can start using visual scripting.

realvirtual.io nodes

With a click of the right mouse button on the graph you can select game4Automation and add a realvirtual.io. Currently there are 5 special nodes.

All nodes have an event entry port on the left side. This port must be connected to an event sender node in order for the node’s logic to execute.

Drive Speed

This node sets the speed of the selected drive. The output event port is always executed once the input event port is set.

Drive State

Drive State reads the status of the selected drive and passes it on to the output ports.

Drive to Target

Sets the drive to move to a specified destination when the start port receives an event. To be informed about the arrived status, you have to execute the update input event port continuously, e.g. by the Fixed Update event.

PLC Output Bool

Reads or writes a bool signal.

Sensor State

Is reading the state of the sensor as soon as the Start port is getting an event.

Building your own nodes

There are a variety of default unity nodes. Please refer to the Unity documentation for all the default nodes.

You can also create your own nodes. The best start is to check the source code of the provided realvirtual.io nodes.

© 2022 in2Sight GmbH - All rights reserved. No part of this publication may be reproduced, distributed, or transmitted in any form or by any means, including printing, saving, photocopying, recording, or other electronic or mechanical methods, without the prior written permission of the publisher.

https://realvirtual.io
https://docs.unity3d.com/Packages/com.unity.visualscripting@1.6/manual/index.html