[Release] Hunger/Thirst HUD V0.3.3 (Added inventory and food shops)

I added some external resources! Try them out

You’re a boss ! can we change the bars color ?

Noted, I will add this in the next version :wink:

Hi when i try to buy item nothing happen in game but that in the console please help :’(

Hi Draziak firts thx for your script its a nice share for comunity

i have a little probleme with foodhub
my frfuel not work with foodhud is setup …

im remove foodhub and frfuel works …

if you use a frfuel 1.0.1 version ?
or its possible to share your frfuel version ?!

thx

Nice man you a big boss !!! :smiley:

You have done the modification to the database?

Weird.
I am using the lastest FrFuel version.
If you are able to know, is there any errors at the startup of FrFuel or foodhud?

No error in console or client
I also have the Gb pack for shops and items

All config are done correctly instaled
and database edit done to

Thank you for your fast response

I’m getting this error too : http://prntscr.com/fa6crv
When i press enter to buy a Water bottle or a Sandwich

That’s really weird because I have just tried it out on my server and it’s working fine

I installed the mod and the externals and followed the README installation aswell, I just did some test by puttng in the items but whenever I press USE, the hud closes and nothing happens, and I cant get the hud back up by pressing K either. any idea why?

Oh i found my error just problem with id of food and drink very thanks for you scripts Draziak

1 Like

Do you have any idea to make it clearer? I will edit my readme with your recommandations!

No error in the console by cons impossible to buy the items, but it uses them the bar regen.
You a good work big boss :smiley:

Hello Draziak, thank you for ur script, but I have a problem with ur new update, when I press use it play the animation but it doesn’t increase my hunger bar or thirst bar :confused:

i thinks just indicate in the scripts where it can change id of items because many server have many items register on database (10 for my server and it’s grow)

(sorry for my bad english i’m french :s )

1 Like

Are you using the good parameter for the appropriate event?
Can you provide me your TriggerEvent here?

function use(item)
    if (ITEMS[item].quantity - 1 >= 0) then
        -- Nice var swap for nothing
        TriggerEvent("player:looseItem", item, 1)
        TriggerServerEvent("item:updateQuantity", 1, item)
        -- Calling the Hunger/Thirst
        if ITEMS[item].type == 2 then
            TriggerEvent("food:eat", ITEMS[item])
        elseif ITEMS[item].type == 1 then
            TriggerEvent("food:drink", ITEMS[item])
        else
            -- Any other type? Drugs??????
        end
    end
end

Details

function ItemMenu(itemId)
    ClearMenu()
    MenuTitle = "Details:"
    Menu.addButton("Utiliser", "use", itemId)
    Menu.addButton("Donner", "give", itemId)
end

My database:

And you installed gb_foodshops?
Or you already have foodshop in your server?

You edited the vdk_inventory database with the value and type field?