mirror of
https://github.com/esx-framework/esx_core.git
synced 2026-09-04 08:13:21 +00:00
fix(esx): Disable autospawning
- Fixes compatibility for players running basic-gamemode or maps
This commit is contained in:
@@ -1,11 +1,14 @@
|
||||
local pickups = {}
|
||||
|
||||
Citizen.CreateThread(function()
|
||||
while NetworkIsPlayerActive(PlayerId()) and not Config.Multichar do
|
||||
Citizen.Wait(5)
|
||||
DoScreenFadeOut(0)
|
||||
TriggerServerEvent('esx:onPlayerJoined')
|
||||
break
|
||||
while not Config.Multichar do
|
||||
Citizen.Wait(0)
|
||||
if NetworkIsPlayerActive(PlayerId()) then
|
||||
exports.spawnmanager:setAutoSpawn(false)
|
||||
DoScreenFadeOut(0)
|
||||
TriggerServerEvent('esx:onPlayerJoined')
|
||||
break
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user