Jump to content

About ACL groups


SkatCh

Recommended Posts

guys i need some help here :

function joinNameCheck(old,new) 
local account = getAccountName(new) 
        if (isObjectInACLGroup("user."..account, aclGetGroup("Trial Staff"))) then  --> this line 
                  adminLoginMessage(source, getPlayerName(source).." logged in - L1") 
            return 
        elseif (isObjectInACLGroup("user."..account, aclGetGroup("Trained Staff"))) then 
            adminLoginMessage(source, getPlayerName(source).." logged in - L2") 
            return 
        elseif (isObjectInACLGroup("user."..account, aclGetGroup("Trusted Staff"))) then 
            adminLoginMessage(source, getPlayerName(source).." logged in - L3") 
            return 
        elseif (isObjectInACLGroup("user."..account, aclGetGroup("Hight Staff"))) then 
            adminLoginMessage(source, getPlayerName(source).." logged in - L4") 
            return 
        elseif (isObjectInACLGroup("user."..account, aclGetGroup("Head Staff"))) then 
                adminLoginMessage(source, getPlayerName(source).." logged in - L5") 
            return 
            end 
            end 
addEventHandler("onPlayerLogin", root, joinNameCheck) 

it's just a part from my script , the problem is when i login i got this warning :

Bad argument @isObjectInACLGroup ' [Excepted acl-group at argument 2 , got boolean]

Link to comment
i don't undrestand , what are u talking about i already tried it .

i mean , you trying to getAccountName , but you use it like this ,

local account = getAccountName(new) 

it should be ,

local account = getAccountName(getPlayerAccount(new)) 
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...