[Release] Food Store V0.1 (27/05)

Food Store V0.1

You can buy Hamburger, Sandwich, Water Bottle and Coke Can in this shop.

to add a food or drink you must do :

  • Create a item like a coffee with value and type in table items in your database
  • if you want create a coffee add this in client .lua
function Coffee()
    TriggerServerEvent("Coffee_Server")
	Menu.hidden = false
end

RegisterNetEvent("Coffee")
AddEventHandler("Coffee",  function()
    TriggerEvent("player:receiveItem", ID OF ITEM, 1)
	Menu.hidden = false  
end)
  • and add a new button
   Menu.addButton("Coffee (PRICE$)", "Coffee", nil)
  • and you add this in server.lua
RegisterServerEvent("Coffee_Server")
AddEventHandler("Coffee_Server", function()
	TriggerEvent("es:getPlayerFromId", source, function(target)
	    if (tonumber(target.money) >= PRICE) then
		TriggerClientEvent("Coffee", source)
		target:removeMoney(PRICE)
		TriggerClientEvent("es_freeroam:notify", source, "CHAR_PROPERTY_BAR_MIRROR_PARK", 1, "Store", false, "Coffee ~g~+1 !\n")
		else
		TriggerClientEvent("es_freeroam:notify", source, "CHAR_PROPERTY_BAR_MIRROR_PARK", 1, "Store", false, "~r~You don't have enought money !\n")
		end
	end)
end)
  • and change ( “ID OF ITEM” and “PRICE”)

Installation

Download : HERE

Requirements

  • Essentialmode 2.X
  • es_freeroam
  • VDK Inventory
  • Food Hud V0.3.3

Changelog

2017-05-27 V0.1

  • Released bk_store

Installation

  • Install requirements
  • Download bk_food folder
  • Put this folder to resources folder in your server
  • Add SQL.sql to your database
  • Add bk_food in AutoStartResource
2 Likes

Frankly it’s clean gg

1 Like

100$ one hamburger :smile:

hello i prefer my gui https://puu.sh/w2Awk/01c95ab56c.jpg

1 Like

And ? Got a bigger ? Happy for you Dude. Stop being a faggot and minimise the work of others. Would love to see your work to comparé… . Just in case… So tired of Kids thinking they are better then everyone else…

Great job and Thanks for the release

*tired of Kids…

2 Likes

hello my friend who are you

Then go use it…? What purpose does your post serve, other than being a kid who shows off his first style edit, gratz, now learn LUA, like them and actually code it.

hello my son, its already coded and finished from 2 months, how can i help you today

Still, nobody here actually cares, and your post serves no purpose, other than making yourself looking good. But guess what, exactly that backfired on you, and now what? You expect us to all go down on knee and pray to you, because you resized a menu, no thanks.

  • If you have further scripts you would like to show off, then go to an appropiate place and do it > The container.
2 Likes

hello my friend who are you

Does this mod replace gb_foodshops ?

Yes he replace the foodshops

2 Likes

Okey nice thanks dude

1 Like

thanks for your nice comment :wink:

Somebody Can give me vkd_inventory with use and Remove item button pleaze (for est and drink)

'foreign key incorrectly formed` I keep getting this error with the sql?

Does it still need essentialmode 2 and freeroam?

@David_Carneiro no it just needs vdk, es, and hud

https://gyazo.com/3add01929995cb91171f22733947ed8e
When I want to load in sql bk_food, does this appear because?

What are the current requirements of this and also…Will it work if i have any other inventory hud?