Player/IsUserGroup

From Garry's Mod
Jump to: navigation, search
 Player:IsUserGroup( )

Contents

Description

Returns true/false if the player is in specified group or not.

Arguments

string groupname

Group to check the player for.

Returns

boolean

isInUserGroup

Examples

Example

Prints in the players console "yes, I'm awesome!" if he's in the superadmin group.

if ( Player(2):IsUserGroup("superadmin") ) then
    print("Yes, I'm awesome!")
end

Output:

"Yes, I'm awesome!" in console.
Personal tools
Navigation