In this video series, I'll explain how you can learn FiveM Scripting in a simple and thoughtful way !
═════════════════════════════════════
Everything for the Client :
ESX = nil
Citizen.CreateThread(function()
while ESX == nil do
TriggerEvent('esx:getSharedObject', function(obj) ESX = obj end)
Citizen.Wait(0)
end
while ESX.GetPlayerData().job == nil do
Citizen.Wait(10)
end
PlayerData = ESX.GetPlayerData()
end)
RegisterNetEvent('esx:playerLoaded')
AddEventHandler('esx:playerLoaded', function(xPlayer)
ESX.PlayerData = xPlayer
end)
RegisterNetEvent('esx:setJob')
AddEventHandler('esx:setJob', function(job)
ESX.PlayerData.job = job
end)
local filename = function()
local str = debug.getinfo(2, "S").source:sub(2)
return str:match("^./(.).lua$") or str
end
print("^6[CLIENT - DEBUG] ^0: "..filename()..".lua gestartet");
═════════════════════════════════════
Everything for the Config :
local filename = function()
local str = debug.getinfo(2, "S").source:sub(2)
return str:match("^./(.).lua$") or str
end
print("^6[CONFIG - DEBUG] ^0: "..filename()..".lua gestartet");
═════════════════════════════════════
Everything for the Server :
ESX = nil
TriggerEvent("esx:getSharedObject", function(obj) ESX = obj end)
═════════════════════════════════════
Link to the LUA Docs : http://www.lua.org/manual/5.1/de/manu...
═════════════════════════════════════
Link to my Discord : / discord
═════════════════════════════════════
There is a lot of work going on in this series of videos so please also give me some feedback to improve some things
Sur cette page du site, vous pouvez voir la vidéo en ligne FiveM Scripting #1 - First FiveM Script [LUA] [German] durée heure minute seconde en bonne qualité , qui a été Téléchargé par l'utilisateur CurryScripts 25 juillet 2022, Partagez le lien avec vos amis et connaissances, sur youtube cette vidéo a déjà été regardée 6,021 fois et il a aimé 132 téléspectateurs. Bon visionnage!