Skip to Content

Exports

Functions you can call from your own scripts to drive the spawn selector.

OpenSpawnSelector

Opens the spawn selector UI for the current player. Use this when you want to trigger the menu from your own script instead of relying on the built-in flow.

Side: client

client.lua
exports.nxs_spawnselector:OpenSpawnSelector()

Example

Open the selector after a custom event, like respawning from death:

client.lua
RegisterNetEvent('myresource:onRespawn', function() exports.nxs_spawnselector:OpenSpawnSelector() end)

If you renamed the resource folder, replace nxs_spawnselector in the export call with whatever you renamed it to.

Need help?

Looking for an export that doesn’t exist yet? Ping us in Discord  and we’ll see about adding it.

Last updated on