Skip to content

Client exports

Exports

setSpawnOverride

Pass in a your own callback function and override the spawning process for existing characters.

exports['character-selector']:setSpawnOverride(function(character)
local ped = PlayerPedId();
-- Set player position
SetEntityCoords(ped, character.x, character.y, character.z);
SetEntityHeading(ped, character.heading);
-- Switch camera to player
SwitchToMultiSecondpart(ped);
end)
  • character: Character
    • Object with selected character data

setSelectSpawnOverride

Pass in a your own callback function and override the spawn selection process for new characters.

exports['character-selector']:setSelectSpawnOverride(function()
-- Switch camera to player
local ped = PlayerPedId();
SwitchToMultiSecondpart(ped);
-- Open a ui showing a selecting of spawns to choose from
end)