NeedGroup

Allows you to limit a job to be joinable only if the player belongs to a certain usergroup.

Alias

NeedGroup, groups

Source

added in Arivia v3

Requires

no additional requirements

Type

table { }

Example

TEAM_CHIEF = DarkRP.createJob( 'Civil Protection Chief',
{
    color           = Color( 5, 255, 0, 255 ),
    model           = 'models/player/combine_soldier_prisonguard.mdl',
    description     = [[The Chief is the leader of the Civil Protection]],
    weapons         = { 'arrest_stick', 'unarrest_stick', 'weapon_deagle2', 'stunstick', 'door_ram', 'weaponchecker' },
    command         = 'chief',
    chief           = true,
    NeedGroup       = { 'vip' },
    category        = 'Civil Protection',
} )

Output

If player selects a job that has a group requirement; they will be presented with an error message in multiple locations:

Notes

Some server owners tend to use CustomCheck to validate groups; we'd recommend using NeedGroup instead for more functionality within Arivia.

Last updated