• respected only jobs!
    4 replies, posted
if (t == TEAM_MASTERTHIEF and not self:IsUserGroup("respected", "admin", "superadmin", "root_user")) then Notify(self, 1, 4, "You must DONATE to become this class!") return end Any ideas why ONLY respected can choose the job?
I don't know that IsUserGroup takes more than one argument. Try seperate self:IsUserGroup's.
[QUOTE=whosdr;31066823]I don't know that IsUserGroup takes more than one argument. Try seperate self:IsUserGroup's.[/QUOTE] Is this what you mean: if (t == TEAM_HITMAN and not self:IsUserGroup("respected")) then Notify(self, 1, 4, "You must be respected to become this class!") return end if (t == TEAM_HITMAN and not self:IsUserGroup("admin")) then Notify(self, 1, 4, "You must be a respected to become this class!") return end
I'm not a LUA coder, but I think it would be more like this : [CODE]if (t == TEAM_HITMAN and not (self:IsUserGroup("respected") or self:IsUserGroup("admin")) ) then Notify(self, 1, 4, "You must be respected to become this class!") return end [/CODE]
[QUOTE=Bloodclaw;31067685]I'm not a LUA coder, but I think it would be more like this : [CODE]if (t == TEAM_HITMAN and not (self:IsUserGroup("respected") or self:IsUserGroup("admin")) ) then Notify(self, 1, 4, "You must be respected to become this class!") return end [/CODE][/QUOTE] It works! thanks dude :D But anyone knows how to add respected only entities?
Sorry, you need to Log In to post a reply to this thread.