SkatCh Posted August 17, 2014 Share Posted August 17, 2014 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
Max+ Posted August 17, 2014 Share Posted August 17, 2014 you need to get the account name like this , "on line 2 " local accName = getAccountName ( getPlayerAccount ( source ) ) -- get his account name if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) Link to comment
SkatCh Posted August 17, 2014 Author Share Posted August 17, 2014 i don't undrestand , what are u talking about i already tried it . Link to comment
Et-win Posted August 17, 2014 Share Posted August 17, 2014 aclGetGroup("Trial Staff") "Trial Staff" was probably not found. I think your ACL Group = "Trail Staff" by accident. Link to comment
Max+ Posted August 17, 2014 Share Posted August 17, 2014 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
SkatCh Posted August 17, 2014 Author Share Posted August 17, 2014 i tried both also i'm pretty sure that i have Trial Staff in my ACL group. Link to comment
Max+ Posted August 17, 2014 Share Posted August 17, 2014 i tried both also i'm pretty sure that i have Trial Staff in my ACL group. Well , maybe you Can't make a space between the words , it has to be connected ? Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now