I got 2 questions dealing with admins.

  1. Instead of searching if the user’s Steam ID, is there anyway to have it check if the user’s group is admin or superadmin?

  2. In Lua, how do you make a player admin? I know there’s either a console command or you can add their Steam ID to a certain .txt, but it’d be nice to know how to do it in Lua easier.

  1. Take a look at this, this, and this.

  2. Not sure.

function ccAdminCheck(ply)

if ply:IsAdmin() or ply:IsSuperAdmin() then

ply.ConCommand(msg, “This player is an admin of some kind!”)


ply.ConCommand(msg, “This player is not an admin!”)

concommand.add(“admincheck”, ccAdminCheck)

  1. ULX did it, look through their addgroup code.

[lua]ply:SetNWString( “UserGroup”, “superadmin” )[/lua]

Ah, I don’t like ULX so much because of how it works. I guess I can browse through that or ASS Mod. Thanks guys!