Without seeing the whole file, itâs hard to know for sure, but FROM EXPERIENCE, youâre missing another âendâ (maybe more).
BUT you have to be careful that the âendâ youâre missing isnât the last one.
Start tracing visually with your eyes, start with the first instance of âif,â âfor,â âwhile,â âdo,â or âfunctionâ (I may be missing more), but for EACH ONE, you should see a corresponding âendâ
Think of it as opening and closing a door.
- For each time you open the door âif statement,â you have to close it once youâre done âend.â
- For each time you open the door âfor loop,â you have to close it once youâre done âend.â
- For each time you open the door âwhile loop,â you have to close it once youâre done âend.â
You should have an equal amount of each type and âendâsâ
If youâre still stuck after trying to find it, please post your code
cl_gangrobbery.lua (4.2 KB)
idk
Ran through OneCompiler fine after setting RegisterNetEvent and Citizen equal to some valueâŚ
the error is from jengijoib/ck/cl_main.lua, not some cl_gangrobbery.lua.
Further, do what Wetter42 said:
cl_main.lua (15.2 KB)
Youre not missing an end youre missing the start of a thread
local talliauki = false
--made by karpo#1943
Wait(4000) --4sec aikaa initiatee ennenku haetaan minkäänlaist dataa
PlayerData = ESX.GetPlayerData()
Wait(1000)
check() --checkataan onko jobilla jengiä
Wait(50)
blippi()
while true do
local wait =
Your code goes directly from a variable set to a while true, and the âendâ for that while loop is followed by another âend)â which is the end for threads or event functions.
The file is expecting like
local talliauki = false
--made by karpo#1943
Citizen.CreateThread(function()
Wait(4000) --4sec aikaa initiatee ennenku haetaan minkäänlaist dataa
PlayerData = ESX.GetPlayerData()
Wait(1000)
check() --checkataan onko jobilla jengiä
Wait(50)
blippi()
while true do
local wait =

