1
0
Fork 0
forked from Simnation/Main

clear Scrip

This commit is contained in:
Max 2025-06-26 05:35:42 +02:00
parent 93bfe0575d
commit de9c6aeb91
3 changed files with 0 additions and 73 deletions

View file

@ -1,23 +0,0 @@
local savedLocations = {}
local QBCore = exports['qb-core']:GetCoreObject()
RegisterNetEvent("qb-relogsave:server:saveLocation", function(cid, coords, heading)
savedLocations[cid] = {
pos = coords,
heading = heading
}
end)
AddEventHandler('QBCore:Server:PlayerLoaded', function(Player)
local cid = Player.PlayerData.citizenid
if savedLocations[cid] then
local pos = savedLocations[cid].pos
local heading = savedLocations[cid].heading
TriggerClientEvent("qb-relogsave:client:restoreLocation", Player.PlayerData.source, pos, heading)
savedLocations[cid] = nil
end
end)