Skip to content

Commit

Permalink
fix: new character spawning at default location
Browse files Browse the repository at this point in the history
Co-authored-by: Manason <clanerp@gmail.com>
  • Loading branch information
mafewtm and Manason authored Nov 16, 2023
1 parent ef9b1d1 commit d2df79d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
7 changes: 6 additions & 1 deletion client/character.lua
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,12 @@ local function spawnDefault() -- We use a callback to make the server wait on th

destroyPreviewCam()

pcall(function() exports.spawnmanager:spawnPlayer() end)
pcall(function() exports.spawnmanager:spawnPlayer({
x = defaultSpawn.x,
y = defaultSpawn.y,
z = defaultSpawn.z,
heading = defaultSpawn.w
}) end)

TriggerServerEvent('QBCore:Server:OnPlayerLoaded')
TriggerEvent('QBCore:Client:OnPlayerLoaded')
Expand Down
2 changes: 1 addition & 1 deletion config/client.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ return {
characters = {
useExternalCharacters = false, -- Whether you have an external character management resource. (If true, disables the character management inside the core)
enableDeleteButton = true, -- Whether players should be able to delete characters themselves.
startingApartment = false, -- If set to false, skips apartment choice in the beginning (requires qbx_spawn if true)
startingApartment = true, -- If set to false, skips apartment choice in the beginning (requires qbx_spawn if true)

profanityWords = {
['bad word'] = true
Expand Down

0 comments on commit d2df79d

Please sign in to comment.