Feat(Contacts): Add contacts

This commit is contained in:
chip committed 2020-08-28 15:04:00 +02:00
1 parent 5ae9f99f42
commit 328ab9b0d0
5 files changed
+88 -11

No files matched your search

+21
View File
@@ -0,0 +1,21 @@
ESX = nil
Citizen.CreateThread(function()
while ESX == nil do
TriggerEvent('esx:getSharedObject', function(obj) ESX = obj end)
Citizen.Wait(0)
end
end)
RegisterNetEvent('phone:sendContacts')
AddEventHandler('phone:sendContacts', function()
ESX.TriggerServerCallback('phone:getContacts', function(contacts)
SendNUIMessage(
{
app = 'BANK',
method = 'setContacts',
data = contacts
}
)
end)
end)