[Release][ESX] Foodtruck

Why you don’t delete the “-master” on your esx folders x) ?

Still getting error
asdddddd

Has anyone managed to add extra items and managed got it to work. I’m having trouble loading the props for hotdog and different burgers and tacos. No errors are showing.
I’ll make a burger and it will take the ingredients. No steak will show. Then it will say it’s cooked.
If I cooked a hotdog, I will see the steak, but at the end there won’t be a hotdog to pick up.

This my problem [ERROR] [MySQL] An error happens on MySQL for query “SELECT * FROM shops WHERE name = ‘Market’ {=}”: Unknown column ‘name’ in ‘where clause’

This is actually a really simple fix, first of all go to esx_foodtruck/server/main.lua and find the line MySQL.Async.fetchAll(“SELECT * FROM shops WHERE name = ‘Market’”, change name to store so it will look like this: MySQL.Async.fetchAll(“SELECT * FROM shops WHERE store = ‘Market’”,

EDIT: Ignore all of that as having ‘Market’ in your db causes serious issues and instead do this:

Change to in your esx_foodtruck.sql file:

INSERT INTO shops (name, item, price) VALUES
(‘Market’, ‘cola’, 100),
(‘Market’, ‘vegetables’, 100),
(‘Market’, ‘meat’, 100)
;

TO:

INSERT INTO shops (store, item, price) VALUES
(‘TwentyFourSeven’, ‘cola’, 100),
(‘TwentyFourSeven’, ‘vegetables’, 100),
(‘TwentyFourSeven’, ‘meat’, 100)
;

In Server/Main.lua(not 100% sure this is even needed):
MySQL.Async.fetchAll(“SELECT * FROM shops WHERE store = ‘TwentyFourSeven’”, (Used to be Market)
Now I can sell those items in TwentyFourSeven/LTDgasoline without any issues. The Market never worked for me and as I’ve said caused serious headaches so I just disabled it.
Here is the result:
Imgur

The easy fix to the market:in the Server file look for
AddEventHandler(‘onMySQLReady’, function ()
MySQL.Async.fetchAll(“SELECT * FROM shops WHERE name = ‘Market’”,
{},
function(result)

Change ‘name’ to ‘store’

Make sure you check in your shops table in the SQL database to see column header for the TwentyFourSeven, RobsLiquor, Market, etc

In my shops table the column header was store. Once I changed from ‘name’ to ‘store’ the market worked as expected.

I modified the code slightly in the tutorial, we can use the market without going through the shop, it works 100%.

i need hlep

Error running call reference function for resource es_extended: citizen:/scripting/lua/scheduler.lua:403: server/classes/player.lua:326: attempt to index a nil value (local ‘item’)
stack traceback:
server/classes/player.lua:326: in upvalue ‘ref’
citizen:/scripting/lua/scheduler.lua:389: in function citizen:/scripting/lua/scheduler.lua:388
[C]: in function ‘xpcall’
citizen:/scripting/lua/scheduler.lua:388: in function citizen:/scripting/lua/scheduler.lua:387
stack traceback:
[C]: in function ‘error’
citizen:/scripting/lua/scheduler.lua:403: in function citizen:/scripting/lua/scheduler.lua:372
Error running system event handling function for resource esx_foodtruck: citizen:/scripting/lua/scheduler.lua:41: Failed to execute thread: citizen:/scripting/lua/MessagePack.lua:830: missing bytes
stack traceback:
[C]: in function ‘error’
citizen:/scripting/lua/MessagePack.lua:830: in method ‘underflow’
citizen:/scripting/lua/MessagePack.lua:465: in field ‘any’
citizen:/scripting/lua/MessagePack.lua:860: in field ‘unpack’
citizen:/scripting/lua/scheduler.lua:626: in field ‘removeInventoryItem’
server/main.lua:90: in upvalue ‘handler’
citizen:/scripting/lua/scheduler.lua:219: in function citizen:/scripting/lua/scheduler.lua:218
stack traceback:
[C]: in function ‘error’
citizen:/scripting/lua/scheduler.lua:41: in field ‘CreateThreadNow’
citizen:/scripting/lua/scheduler.lua:218: in function citizen:/scripting/lua/scheduler.lua:182

Hi there are you still working on this project?

Because it’s a nice idea but it’s full of problems, like:

CANNOT SEE THE SOCIETY MONEY
DON’T HAVE A VAULT TO PUT STUFF
THE SHOP TO BUY INGREDIENTS IT’S GLITCHY

and a lot of other stuff

1 Like

Are any devs for this resource still active.

Im just wanting abit of advice reference prehaps making so once the items finished cooking and it pops up saying “food cooked” u get the actual item added to ur inventory as a useable item so u can give it to other civs.

Any help would be greatful.

Cheers

Amazing release! Is anyone know what to add to make bbq animation when start cook?

1 Like

Deposit money doesn’t work? or is it just me. It throws me error in society at line 41 or 39 im not so sure now.

For those of you who need a fix to make the society work you need to add a line in server/main.lua around line 8 after this:

TriggerEvent('esx_phone:registerNumber', 'foodtruck', 'Client FoodTruck', false, false)

Add this:

TriggerEvent('esx_society:registerSociety', 'foodtruck', 'Foodtruck', 'society_foodtruck', 'society_foodtruck', 'society_foodtruck', {type = 'public'})

i have install the mod and i got some problems.sometimes after finish cooking the tacos/burger cannot be removed and it can keep picking it out so that they can make unlimited food.How can i fix this problem?

for vrp pls?

I was JUST about to post this, as I found the error in my server as well and was able to correct it.

1 Like

can anyone help me with adding an armory for this script. Id like for the org leader to be able to hold storage. Let me know. Thanks

Where is the cooking spot? i cant cook anywhere

Any ideas? When i spawn the grill, nothing happen. I cant cook.