ULX customCheck for donator jobs not working/

Here is the code in my jobs/lua in pastebin.

There is no error that happens, but when I set my self to donator in game the jobs with this customCheck are not coming up.

Use GetNWString?

[lua]function(ply) return ply:GetNWString(“usergroup”) == “donator” or ply:IsAdmin() end[/lua]
There you go.

No need for IsSuperAdmin either.

I changed the code to what you wrote, and it still isn’t changing anything.

customCheck = function(ply) return ply:GetNWString(“usergroup”) == “donator” or ply:IsAdmin() end,
CustomCheckFailMsg = “You don’t have the required rank to complete this action!”,

  • snip -

If you want to you can try my generator: http://www.thecodingbeast.com/tools?id=customcheck

He’s using ULX. That’s what he wrote in the title at least.

I tried your generator, but nothing happened.

[editline]5th September 2014[/editline]

That is correct, I am using ULX as the title states.

The code I am now using looks like this :

TEAM_SAMUS = AddExtraTeam(“Samus Aran”, {
color = Color(100, 100, 100, 255),
model = {
description = [[You are the hitman of the future.

Get paid to take out serious criminals around the galaxy.]],
weapons = {"weapon_powerbeam"},
command = "samus",
max = 1,
salary = 500,
admin = 0,
vote = false,
hasLicense = false,
customCheck = function(ply) return CLIENT or table.HasValue({"superadmin", "admin", "donator"},
ply:GetNWString("usergroup")) end,
CustomCheckFailMsg = "You don't have the required rank to complete this action!"


While talking with @CodingBeast we realized that the code was fine and everything should work…

When doing your donator class don’t be an idiot and make sure your admin value in your code is set to 0.