A custom Godot 4+ node that generates a unique ID to be concatenated to, or replace the parent node's name.
This node can be added as a child of an existing node. The parent node will then have its name either concatenated with the ID or replaced by the ID.
- Can generate 3 different length of unique ID: Short, Medium, Long.
- Ability to concatenate the ID to parent name or replace the parent name.
- Option to add a string separator when concatenating the ID.
- Option to set the unique ID as persistent (saved to disk).
- Automatically free this custom node after use.
- Go to the
AssetLib
in the Godot Editor. - Type "unique" to search for the
UniqueId
node. - Select the asset and click Download.
- Download as a ZIP file from this repository or
- Clone this repository
After enabling this plugin, you can add the UniqueId
node as a child of another node and it will add or replace a Unique ID to the parent node.
- Right-click on a node or press Ctrl+A.
- Type "unique" on the Search textbox of the Create New Node form to filter the node list and easily find the
UniqueId
node.
- Double-click the
UniqueId
node to add as a child of the node.
- Adding more than one
UniqueId
node will result in creating a sequence of Unique IDs. The IDs will either be concatenated or replace the parent name, which ever comes first. - Adding the
UniqueId
node as the only node, or a child of the root node, will result in changing the name of the root node.
Head on over to my website at https://plugins.jbsnippets.com to read more about this plugin and other plugins that I've been creating during my game development journey.