[Release][ESX] Foodtruck

Another script today ^^

Introducing the foodtruck.
Very easy to add new recipes (check the config file, you can cook tacos and burger).

You can spawn props:

  • BBQ (to cook, the cooked food will pop on the side of the bbq once cooked)
  • Chair and table (you should use esx_sit, like that your clients will be able to sit on your chairs)

Required:

  • esx_jobs (for the packaged_chicken item)
  • esx_shops (to go buy ingredients in small markets)


Thanks to @deldu for the SQL file

@Don is actually translating into english (only french atm)

17 Likes

It’s great, keep up the great work about the ESX.

Thanks for Sharing this job and for the time you spent to make it work! Nice!

1 Like

EN Translation done. Check git for the updated version.

1 Like

I can’t find the ingredients in the show?
Why??
I did add the sql…

In the “show” ? What is the “show” ???

Was supposed to be shop xd
But I found out they got their own shop.
How can I do som job grade 0 also can buy from there?

I can’t access the money from the billing in the boss menu, withdraw and deposit function does not do anything, not even returning an error. Any ideas?

since the addition of script itself some shop no longer works can you help me?

I’ve also seen an issue with the job related market missing the items to choose from. When implementing, I tested and it worked great. Has there been any changes?

How can I open the food menu and cook the beef? :smiley: I love the script btw.I can open the menu with F6 and I got all the stuff from the market but how can I open other stuff?And is there any way I can go inside the car to sell things from there or no?

Hey guys, what is this error, I tryed everything. Do you know how to fix?
Sem%20t%C3%ADtulo

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%.