Creating Gameplay and Other Behaviors with Script Canvas

Script Canvas is a general purpose, visual scripting environment for Open 3D Engine (O3DE) that you can use to create runtime logic and scripted behaviors for any entity. Script Canvas offers an approachable yet powerful environment to author behaviors using the same framework as Lua and C++. You can use Script Canvas to create scripts for game logic without needing to know how to code, and take advantage of O3DE messaging systems to produce small, event-driven scripts that don’t require complex logic to maintain states.

Script Canvas is an extensible system. You can build your own reusable Script Canvas functions from within the Script Canvas Editor, and use Script Canvas nodes that are created automatically from functionality exposed through the behavior context . The behavior context reflects runtime code, making it accessible to scripts by providing bindings to C++ classes, methods, properties, constants, and enums. The behavior context also provides bindings for O3DE’s AZ::Event and EBus messaging systems, giving you the ability to use Script Canvas nodes to dispatch and handle messages and events.

To extend Script Canvas even further, you can create your own custom nodes (“nodeables”) using the powerful automatic generation capabilities of the AzAutoGen system.

The ease of use of this visual scripting environment does not come at the cost of performance when compared to the more traditional Lua model. To maintain similar performance, Script Canvas graphs are translated by the Asset Processor to optimized Lua script.

To use Script Canvas in your O3DE project, you must enable the Script Canvas Gem and its dependencies.

TopicsDescription
Get Started GuideLearn the basic concepts of Script Canvas and the interface of the Script Canvas Editor.
Editor ReferenceA reference of Script Canvas Editor features, menu options, and tools.
Creating New NodesLearn about the different ways to create new Script Canvas nodes.
Programmer GuideLearn how to expose runtime code in Script Canvas using the behavior context, and how to create custom nodes (“nodeables”) using AzAutoGen.
Best PracticesGet tips on best practices when using Script Canvas.
DebuggingLearn how to use the Script Canvas Debugger.