Read the FAQ
Cheers Fella
How can I increase the space between icons?
In the css…
Anyone integrated this with the mumble-voip stuff?
If you could give some guidance it would be great.
Thanks,
Can someone tell me how to make it with saltychat compatible?
alright dont know if this is happening to anyone else but the hud isnt showing for me. And yes I made sure its started pog. I cleared my cache still nothing. But the only thing that is working on the /showmenu so.
replace: needsUpdate() only add an “citizen.thread” down of tutorial Opax up here
------------
function needsUpdate()
if Data.PlayerLoaded then
local hungerValue, thirstValue
TriggerEvent('esx_status:getStatus', 'hunger', function(hunger)
hungerValue = (hunger.val / 1000000) * 100
end)
TriggerEvent('esx_status:getStatus', 'thirst', function(thirst)
thirstValue = (thirst.val / 1000000) * 100
end)
-- Grab needs values.
-- Make sure it's on a 0 - 100 scale
SendNUIMessage({
type = 'update',
hunger = hungerValue,
thirst = thirstValue
})
end
SetTimeout(1000, needsUpdate)
end
needsUpdate()
---------------------------
-- Event Handlers --
---------------------------
RegisterNetEvent('scrubz_hud:Init')
AddEventHandler('scrubz_hud:Init', function()
local plyPed = PlayerPedId()
local currentHealth = GetEntityHealth(plyPed) - 100
local currentArmor = GetPedArmour(plyPed)
Data.Health = currentHealth
Data.Armor = currentArmor
TriggerEvent('esx_status:getStatus', 'hunger', function(hunger)
hungerValue = (hunger.val / 1000000) * 100
end)
TriggerEvent('esx_status:getStatus', 'thirst', function(thirst)
thirstValue = (thirst.val / 1000000) * 100
end)
-- Also grab current needs values (0 - 100 scale)
SendNUIMessage({
type = 'init',
health = currentHealth,
armor = currentArmor,
hunger = hungerValue,
thirst = thirstValue,
stress = stressValue
})
Data.PlayerLoaded = true
end)
--- here where the magic happens---
Citizen.CreateThread(function()
while true do
Citizen.Wait(10000)
TriggerEvent('scrubz_hud:Init', source)
end
end)
Idk what to tell you. I can literally assign values to the various needs via:
Data = {
PlayerLoaded = false,
Player = {
Health = 0,
Armor = 0,
Hunger = 100,
Thirst = 100,
Stress = 0
}
}
And I can start it via a command like so with no issues.
RegisterCommand('init', function()
local plyPed = PlayerPedId()
local currentHealth = GetEntityHealth(plyPed) - 100
local currentArmor = GetPedArmour(plyPed)
Data.Player.Health = currentHealth
Data.Player.Armor = currentArmor
SendNUIMessage({
type = 'init',
health = Data.Player.Health,
armor = Data.Player.Armor,
hunger = math.floor(Data.Player.Hunger),
thirst = math.floor(Data.Player.Thirst),
stress = math.floor(Data.Player.Stress),
})
Data.PlayerLoaded = true
end)
It works without issues for me. You have to be doing something wrong.
This is just flat out wrong. You only have to trigger the ScrubzHud:Init event handler ONCE. Why in the world would you fucking loop that in a thread. That event is ONLY used to start the hud. It’s not something thats meant to be triggered more than once, let alone every 10 seconds. Not only that, but idk why you’re including source when triggering a client event FROM the CLIENT. Specifying a user to trigger the event on (source, -1, etc) is only done when triggering a client even FROM the SERVER. Please refrain from giving “fixes” to issues when you have no idea what you’re doing.
I didn’t try to fix your script I was trying to give Zoku an idea of how to call the script and work I am new to FIVEM programming and I answered wrongly without selecting reply sorry my mistake
Love your hud, could you just give some guidance on the right path to have the mumble-voip events properly showing on the ‘speaker’ of your HUD? 
Don’t want to mess up what is already perfect but it would be great to have it working.
On the mumble-voip\client.lua i did some tests on the ‘if playerTalking’:
if playerTalking then
-- crashys fala boi
-- exports['scrubz_hud']:toggleVoiceActive(true)
--exports['scrubz_hud']:toggleVoiceActive(bool)
SendNUIMessage({
type = 'toggleVoice',
value = true
})
else
-- exports['scrubz_hud']:toggleVoiceActive(false)
SendNUIMessage({
type = 'toggleVoice',
value = false
})
end
I know the location should be this one (i tried print out to the console and when the voice is active it triggers that), however, i’m getting an invalid of that export… I feel i’m missing something very basic (because i’m not a proper developer so i’m just looking around).
Could you guide me a little bit please?
Thank you,
The exports work fine. I know a few people who are using it with both mumble and “He-Who-Must-Not-Be-Named” without issue.
But you could easily just thread NetworkIsPlayerTalking() to detect if the player is talking or not with mumble.
On a side note, whatever it is you were trying to do above, won’t work since the SendNUIMessage bit you put is meant for my resource, and won’t work on other resources. You can’t trigger a regular function inside 1 resource from a different resource by just calling the function, and the same applies to nui stuff.
But like I said, just thread the native above with a bool that you can toggle so you’re not constantly sending nui messages, and instead just send 1 on each change.
Your words are wise and i shall try to apply such wisdom. 
Thanks mate, i will try it, sorry for such noob ‘comments’ on my end, just trying to make it work. 
Just to ‘share’ what I have worked out with the wisdom of Scrubz:
I didn’t touch the mumble-voip stuff, i simply worked with the cl_hud.lua:
On the thread needsupdate():
-- mumble
local playerId = PlayerId()
local playerTalking = NetworkIsPlayerTalking(playerId)
local playerProximity = NetworkGetTalkerProximity(playerId)
SendNUIMessage({
type = 'toggleVoice',
value = playerTalking
})
-- 1 for whisper = 2.5 (33%), 2 for normal = 8.0 (66%), 3 for shout = 20.0 (100%)
if(playerProximity == 2.5) then
--whisper
setLevel = 1
end
if(playerProximity == 8.0) then
--normal
setLevel = 2
end
if(playerProximity == 20.0) then
--shout
setLevel = 3
end
SendNUIMessage({
type = 'voiceLevel',
value = setLevel
})
The only ‘thing’ I notice is it’s very fast (like 1s to update the status of the icon (probably due to the timeout of the thread):
SetTimeout(1000, needsUpdate)
As i didn’t want to mess up that to a lower value without the measure of performance, i’m ok with that for now. 
I have one question if you could help (not that great at css/js), i’m trying to change the circle color of the speaker (whisper, normal, shout) for a more ‘graphical’ view of how i’m speaking.
Could you give me some guidance?
Idk what you mean. Whisper = 33% fill, Normal = 66% fill, and Shout = 100% fill. I’m not sure how much more graphical you can get. You can change the default and speaking colors by utilizing the menu.
This is nice
Hey,
What I was trying to do is more set the graphic at 25% (when whister), set it at 50% (when normal) and at 100% (when shout).
It was just to be more intuitive as the whisper and normal may sound confusing to some people. 
Oh well you wouldn’t be able to do that via css. I use inline styling for that.