Requests a unique userdata slot identifier.
The userdata slot system can be used by plugins to attach plugin-specific data to a specific node and retrieve it again later.
Generally a plugin should request one or more unique data slots on initialization and keep them open for the lifetime of the plugin. It does not need one per node - the userdata slot handle should be considered the unique slot identifier for plugin data on ALL nodes. Using more than one is only necessary if the plugin needs to store more than one piece of data on a single node, and even then only in the case where storing it in a struct in the first slot is not appropriate.
This data is not managed by the application, so it is up to the plugin to make sure it removes any userdata it adds before closing its user slot handle.
- Returns
slot handle, or 0 on error
- Permission: SC_MODIFY