[HELP] Trew-Hud-UI doesn´t show

Hey i have a problem that is Really Anoying.
The Ui that i Use doesn´t show up when i join.


but when i type " /toggleui " twice it shows.
but whithout food/thirst

Does somebody have an Idea how to fix this?

Thanks in advantage.

When your server starts does it state the resource has been started? Any errors.
We need information to help resolve the issue. What have you done already?

1 Like

I looked in F8 in the server console, but no errors.
I even installed it 6 times new without editing the config or something but it doesn´t work

2 Likes

Same error here ,it might be some new uptade idk

Still not fixed? At first it worked but then it suddenly stopped working

hey
same… any solution ?

I managed to fix the problem of the ui not opening when you first login by changing ui.html inside the html folder

Change for everything that you want to show the style=“display:none;” to style=“display:block;”

19 Likes

The problem is not with that line in the UI file but with this.

In the client.lua

Go the line 671

Change this;
AddEventHandler('onClientMapStart', function()

To this
AddEventHandler('esx:onPlayerSpawn', function()

12 Likes

This works!!

2 Likes

This didn’t seem to change anything for some reason

1 Like

Are you on ESX

3 Likes

I’ve sorted it, turns out it was a resolution problem on one of the players PC’s

Worked, thx

my setting are already like that and i have that same error , the HUD only appears if i toggle 2 times
pls help

1 Like

Bro you are wrong , you need to write AddEventHandler(‘onClientMapStart’ , function()
just fixed mine

5 Likes

Thank you dude, it fixed my problem too.

1 Like

Type this in the client.lua
after u put that you can use /toggleui2 in the chat to have the food,thirst…
your welcome

local toggleui2 = false

RegisterCommand(‘toggleui2’, function()

if not toggleui2 then

    SendNUIMessage({ action = 'element', task = 'disable', value = 'hunger'})

    SendNUIMessage({ action = 'element', task = 'disable', value = 'thirst'})

    SendNUIMessage({ action = 'element', task = 'disable', value = 'stamina'})

    SendNUIMessage({ action = 'element', task = 'disable', value = 'armor'})

    SendNUIMessage({ action = 'element', task = 'disable', value = 'health'})

else

    if (Config.ui.showHunger == true) then

        SendNUIMessage({ action = 'element', task = 'enable', value = 'hunger' })

    end

    if (Config.ui.showThirst == true) then

        SendNUIMessage({ action = 'element', task = 'enable', value = 'thirst' })

    end

    if (Config.ui.showStamina == true) then

        SendNUIMessage({ action = 'element', task = 'enable', value = 'stamina' })

    end

    if (Config.ui.showArmor == true) then

        SendNUIMessage({ action = 'element', task = 'enable', value = 'armor' })

    end

    if (Config.ui.showHealth == true) then

        SendNUIMessage({ action = 'element', task = 'enable', value = 'health' })

    end

end

toggleui2 = not toggleui2

end)

1 Like

grazie

It really worked on mine!

This is not working for me. Can u give me another one that doesn’t need to type in the chat ‘/toggleui2’