[RELEASE] ESX/VRP Job Counter Display V2

Hello, sorry for taking a long time to answer, but I had a broken PC.

Mmm, are you getting any errors on the console?

Hello, sorry for taking a long time to answer, but I had a broken PC.

Well, I was doing it and I was able to do it, but when someone left the service, he kept at +3, he did not return to 2, I will have to look again to see if I adapt again

Hello, sorry for taking a long time to answer, but I had a broken PC.

first of all tell you to write in english because to be an english forum they force you to use their language and they can ban you for that reason … it is a tip

Maybe I did not detect the mechanic counter because your mechanic job will be called differently, look in your database in the jobs db job name and see if it is the same as in the script, if it is different you have to change the script name to yours

Could you send me how you did it? And so I have a basis to be able to modify it?

yes thanks, I detected that there were two errors in the main lua there was a name “mecano” and also the code xplayer.player.setgroup does not exist maybe it is from a past version the correct code with which it works is xplayer.setgroup, I appreciate for its script and for its time, it works wonderfully

where do you change it to just say ID

hello, in the html delete the lines of the counters and just leave the line of the id

how does it know who are cops bc im a cop but it doesnt show me as one

I don’t understand what you want to tell me

Great Script exactly the one that I was looking for, I just have a quick question where or how can I change the position from being in the low left corner to be in the left middle side of the screen?
I know this is the option but I don’t understand how to change it ,… please I need some help.

DrawText(x - width/2, y - height/2 + 0.005)

I have the Threw HUD and the time and the street name they are on that corner I just wanted to be a little up so is not behind.

you have to change it in the ui.css

good ! , I need to put the job counter in line and not next to each other as it appears there! , some way to do it? greetings from Argentina

client > main.lua > line 76:

elseif v.job == 'police' then

            police = police + 1

            if police > 3 then

                police = '+3'

            end

For all works, u can make that

Hello, you have to modify the ui.html and ui.css, greetings from Spain

Incredible work …

Tremendo, esta buenardo

yes or no, the best pain gaming shooter

Please speak English on forum, thanks.

Actually, when you get to the police > 3 then
part, you’re switching your INT value (3) to a str (+3), so, whenever NEXT cop will login, you’re going to be performing an invalid mathematic operation between an str and an int value…you’ll get an error saying “attempt to compare str with int” or something like that…
You have to do it like this:
elseif v.job == ‘police’ then

           police = police + 1

            if police > 3 then

                policevalue = '+3'
           else
                policevalue = police

            end

and then on the html make it like police = policevalue

dont copy the exact code, it’s written from my cellphone, just try to understand the mistake and look for something like this to solve it yourself xD.

1 Like

Perfect Hiso, thanks!

1 Like