Node Editor

Background

My ever-growing interest in creating tools that are easy to understand and use led me into this challange. I love working with interactive tools that give a lot of feedback to the user. Creating a way for our team to use visual scripting sounded to cool not to try. 

Goal

My goal was to learn more about how tools can lower the barrier to entry for other disciplines that may not be familiar with programming. Therefore, a node editor that allows you to create the core of the game, similar to Unreal Engine, seemed to me to be the most appropriate tool.

Cross Blueprints

Since we didn't have a way to communicate between the blueprints. I had to implement a system that would fit our engine design, where we used a entity component system instead of a game object oriented. This ment that each entity could have a new unique ID each time we loaded in a level. By using the Label-Component I was able to find a way to get the current ID of a certain entity. Adding a node that allowed the user to write the specific name to search for in the targets blueprint, gave us the ability to get variables cross blueprints. 

Custom Events

We had already created the functions needed to create custom variables, but these had a limitation in output. The nodes that are automatically created can either return the value of the custom variable or assign a value. The idea behind creating custom events was that they could act as optional starting paths. This allows the user to execute new paths depending on whether the conditions for the custom events are met.

Triggers

To further open up the possibilities of communication between the Blueprints, I have implemented a node that allows Blueprint A to trigger custom events in Blueprint B.

Timers

We needed a timer that could travel a different path depending on if the condition for the duration is met. The node also needed to return a value between 0 and 1 each frame that represent the alpha value to make it possible for lerping. 

One of the challanges was making the "On Completed" trigger at the right frame. We noticed a one frame delay, making it unreliable. To solve this I got the opportunity to learn and use Callback functions. 

Future Improvements

To be able to use the same blueprint for more than one entity and to use unique values for variables, we had to create workarounds. I want to further improve the editor by introducing the possibility to assign custom values to each entity using the same blueprint.

The editor was easy to use, although it could be a bit overwhelming for one of the larger designs, like the example above which is our main character in Hatchling. To fix this, I will add comment boxes to better structure the blueprints.



©2022 by Alexander Maier