mirror of
https://github.com/citizenfx/cfx-server-data.git
synced 2025-12-12 14:24:02 +01:00
initial
This commit is contained in:
26
resources/[system]/sessionmanager/client/sessionstarter.lua
Normal file
26
resources/[system]/sessionmanager/client/sessionstarter.lua
Normal file
@@ -0,0 +1,26 @@
|
||||
-- more rline stuff, this does some late-term session management (which I think has some race condition with launching the network player?)
|
||||
AddEventHandler('sessionInitialized', function()
|
||||
if IsThisMachineTheServer() then
|
||||
-- unknown stuff, seems needed though
|
||||
NetworkChangeExtendedGameConfigCit()
|
||||
|
||||
CreateThread(function()
|
||||
Wait(1500)
|
||||
|
||||
if not NetworkIsSessionStarted() then
|
||||
NetworkStartSession()
|
||||
|
||||
while NetworkStartSessionPending() do
|
||||
Wait(0)
|
||||
end
|
||||
|
||||
if not NetworkStartSessionSucceeded() then
|
||||
ForceLoadingScreen(0)
|
||||
SetMsgForLoadingScreen("MO_SNI")
|
||||
|
||||
return
|
||||
end
|
||||
end
|
||||
end)
|
||||
end
|
||||
end)
|
||||
Reference in New Issue
Block a user