Hi, What should I do to hide the names of other players and only show my name ?like the screenshot.
If there is a toggle that allows admin to control would be so great!
thanks for answer.
Does anyone know how to change the keybinding to Up Arrow?
I tried many different things in the [ ] like
[UPARROW]
[ARROWUP]
[ARROW]
Even the id of it.
And nothing worked, does anyone know?
Does not work.
yes don’t worry, is hard to find ppl from your region on this kind of forums
for anyone interested in how i got game name not the rp name to show on the list. open up server.lua then go to line 56 connectedPlayers[playerId].name = firstname .. " " .. lastname
replace it with connectedPlayers[playerId].name = xPlayer.getName()
it worked like a charm.
I believe it should be “TOP”
I will try it, when I get on my pc and if not than I will ask around.
It doesnt work on my server…
Hello!!!
How can I show the firstname and the surname in the scoreboard?? Like in the screeshot in the post.
Actually in my server, the name show the Steam name.
Thanks guys
But you have to create thats variable in anyplace, right?
I mean to “firstname … " " … lastname”
I want to get the First and last name too unstead of steam can you tell us what to do please?
in your __resource.lua:
Replace your server_script by this:
server_script{
‘@mysql-async/lib/MySQL.lua’,
'server/main.lua’
}
Then, you open server/main.lua and replace the AddPlayerToScoreboard method by this:
function AddPlayerToScoreboard(xPlayer, update)
local playerId = xPlayer.source
local identifier = GetPlayerIdentifiers(playerId)[1]
local result = MySQL.Sync.fetchAll("SELECT * FROM users WHERE identifier = @identifier", { ['@identifier'] = identifier })
local firstname = result[1].firstname
local lastname = result[1].lastname
connectedPlayers[playerId] = {}
connectedPlayers[playerId].ping = GetPlayerPing(playerId)
connectedPlayers[playerId].id = playerId
connectedPlayers[playerId].name = firstname .. " " .. lastname
connectedPlayers[playerId].job = xPlayer.job.name
if update then
TriggerClientEvent('esx_scoreboard:updateConnectedPlayers', -1, connectedPlayers)
end
if xPlayer.player.getGroup() == 'user' then
Citizen.CreateThread(function()
Citizen.Wait(3000)
TriggerClientEvent('esx_scoreboard:toggleID', playerId, false)
end)
end
end
Thats all you have to do…look easy but if you haven’t any idea (like me hahah) is complicated…
Can i show you what i did on discord?
Hello! I have superadmin and my friend too, and we are in scoreboard but otherplayers, that have default group, they aren´t in the scoreboard.
nice. how to do that bro @Djkamikc
HOW TO DO THIS arrangement
Do you know?