Is this working on Gmod 13 ?

Is this Code working for Gmod 13 ?
When its not could someone fix it for me?
I would be really thankfull ! :smiley:

[lua]hook.Add(“HUDPaint”, “AdminESP”, function()
for _, ply in (player.GetAll()) do
if (ply != LocalPlayer()) and (ply:IsAdmin()) then
local x, y = ply:GetPos():ToScreen()
draw.SimpleText("[ADMIN]" … ply:Nick(), “UIBold”, x, y, Color(255, 0, 0, 255), TEXT_ALIGN_CENTER, TEXT_ALIGN_CENTER)
end
end
end)[/lua]

Check it yourself and no we won’t fix your shit

It’s actually not even his… http://forum.facepunch.com/showthread.php?t=1179667

He copied/pasted it… Anyway, what error is it outputting? Have you ran the code yet?

Yes i ran the code on my Server, i tryed editing

IsAdmin to IsUserGroup(“group”)

My problem is it wont show up Ingame when someone have this Group

Also i tryed to edit (ply != LocalPlayer()) to (ply:IsPlayer())

can you even read the code?
it uses draw.SimpleText - function from clientside drawing module;:ToScreen - clientside function that requires render matrix = script is supposed to work on client, not on server.

anyway, yes it will work. simply, don’t change anything.

It should pop-up above players the players head for other users

yes, but you said you were trying to run this on server, while it’s supposed to be ran on clients.

If you want that other people see it as well, you will have to put the code in a lua file that is downloaded from the server and then client-side executed.

Well thank u guys, appricate ur help :slight_smile: