forked from Simnation/Main
24 lines
518 B
Lua
24 lines
518 B
Lua
![]() |
if not ESX then
|
||
|
local exportExists, obj = pcall(function()
|
||
|
return exports.es_extended:getSharedObject()
|
||
|
end)
|
||
|
|
||
|
if exportExists then
|
||
|
ESX = obj
|
||
|
else
|
||
|
TriggerEvent('esx:getSharedObject', function(esx)
|
||
|
ESX = esx
|
||
|
end)
|
||
|
|
||
|
while not ESX do
|
||
|
Wait(100)
|
||
|
end
|
||
|
end
|
||
|
end
|
||
|
|
||
|
---Displays a notification to the player
|
||
|
---@param message string
|
||
|
function DisplayNotification(message)
|
||
|
ESX.ShowNotification(message, 'error')
|
||
|
end
|