So I have a script for DarkRP to draw text on players when I look at them
local localplayer function DrawEntityDisplay() ent = localplayer:GetEyeTrace().Entity for k, v in pairs(player.GetAll()) do if ent:IsPlayer() == true then print(ent) local pos = ent:EyePos() draw.DrawText(ent:Nick(), "DermaDefault", pos.x, pos.y + 15, Color(255,255,255,255)) else return end end end function GM:HUDPaint() localplayer = localplayer and IsValid(localplayer) and localplayer or LocalPlayer() if not IsValid(localplayer) then return end DrawEntityDisplay() self.Sandbox.HUDPaint(self) end
It prints that its a player but it doesnt draw the text. Any help is appreciated. There are also no errors in the console.