mirror of
https://github.com/esx-framework/esx_core.git
synced 2026-09-04 16:23:21 +00:00
+1
-13
@@ -710,7 +710,7 @@ INSERT INTO `vehicle_categories` (`name`, `label`) VALUES
|
|||||||
--
|
--
|
||||||
|
|
||||||
CREATE TABLE `vehicle_sold` (
|
CREATE TABLE `vehicle_sold` (
|
||||||
`id` INT(11) NOT NULL,
|
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||||
`client` varchar(50) NOT NULL,
|
`client` varchar(50) NOT NULL,
|
||||||
`model` varchar(50) NOT NULL,
|
`model` varchar(50) NOT NULL,
|
||||||
`plate` varchar(50) NOT NULL,
|
`plate` varchar(50) NOT NULL,
|
||||||
@@ -848,24 +848,12 @@ ALTER TABLE `user_licenses`
|
|||||||
ALTER TABLE `vehicle_categories`
|
ALTER TABLE `vehicle_categories`
|
||||||
ADD PRIMARY KEY (`name`);
|
ADD PRIMARY KEY (`name`);
|
||||||
|
|
||||||
--
|
|
||||||
-- Indexes for table `vehicle_sold`
|
|
||||||
--
|
|
||||||
ALTER TABLE `vehicle_sold`
|
|
||||||
ADD PRIMARY KEY (`id`);
|
|
||||||
|
|
||||||
--
|
--
|
||||||
-- Indexes for table `whitelist`
|
-- Indexes for table `whitelist`
|
||||||
--
|
--
|
||||||
ALTER TABLE `whitelist`
|
ALTER TABLE `whitelist`
|
||||||
ADD PRIMARY KEY (`identifier`);
|
ADD PRIMARY KEY (`identifier`);
|
||||||
|
|
||||||
--
|
|
||||||
-- Indexes for table `vehicle_sold`
|
|
||||||
--
|
|
||||||
ALTER TABLE `vehicle_sold`
|
|
||||||
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
|
|
||||||
|
|
||||||
--
|
--
|
||||||
-- AUTO_INCREMENT for table `addon_account_data`
|
-- AUTO_INCREMENT for table `addon_account_data`
|
||||||
--
|
--
|
||||||
|
|||||||
@@ -199,7 +199,7 @@ end)
|
|||||||
local function loadNPC(index, netID)
|
local function loadNPC(index, netID)
|
||||||
CreateThread(function()
|
CreateThread(function()
|
||||||
while not NetworkDoesEntityExistWithNetworkId(netID) do
|
while not NetworkDoesEntityExistWithNetworkId(netID) do
|
||||||
Wait(1)
|
Wait(200)
|
||||||
end
|
end
|
||||||
local npc = NetworkGetEntityFromNetworkId(netID)
|
local npc = NetworkGetEntityFromNetworkId(netID)
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
RegisterNetEvent('esx:playerLoaded') -- Store the players data
|
RegisterNetEvent('esx:playerLoaded') -- Store the players data
|
||||||
AddEventHandler('esx:playerLoaded', function(xPlayer, isNew)
|
AddEventHandler('esx:playerLoaded', function(xPlayer, isNew)
|
||||||
print("Player Loaded. New | " .. isNew)
|
print(('Player Loaded. New | %s'):format(isNew))
|
||||||
ESX.PlayerData = xPlayer
|
ESX.PlayerData = xPlayer
|
||||||
ESX.PlayerLoaded = true
|
ESX.PlayerLoaded = true
|
||||||
end)
|
end)
|
||||||
@@ -23,7 +23,7 @@ end)
|
|||||||
|
|
||||||
function OnPlayerData(key, val, last)
|
function OnPlayerData(key, val, last)
|
||||||
if type(val) == 'table' then val = json.encode(val) end
|
if type(val) == 'table' then val = json.encode(val) end
|
||||||
print('PlayerData.'..key..' was set to '..val)
|
print(('PlayerData.%s was set to %s'):format(key, val))
|
||||||
if key == 'job' then
|
if key == 'job' then
|
||||||
if last.name ~= val.name then
|
if last.name ~= val.name then
|
||||||
print('You are now in a different job')
|
print('You are now in a different job')
|
||||||
|
|||||||
Reference in New Issue
Block a user