Nicolas ECM Posted March 17, 2014 Share Posted March 17, 2014 Hi who could tell me how to make only those of the group in acl can enter the anbu anbu team with a command function criminal(player) local team = getTeamFromName("Anbu") if ( team ) then if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Anbu" ) ) then setPlayerTeam(player, team) setPlayerNametagColor(player, 225, 0, 0) local accName = getAccountName ( getPlayerAccount ( thePlayer ) ) else outputChatBox ( "Usted no es Anbu!",thePlayer) end end end addCommandHandler("itac", criminal) help me Link to comment
Castillo Posted March 17, 2014 Share Posted March 17, 2014 "accName" is not defined. You must use: getPlayerAccount + getAccountName Link to comment
Nicolas ECM Posted March 17, 2014 Author Share Posted March 17, 2014 how it would be? Link to comment
Castillo Posted March 17, 2014 Share Posted March 17, 2014 function criminal ( thePlayer ) local accName = getAccountName ( getPlayerAccount ( thePlayer ) ) local team = getTeamFromName("Anbu") if ( team ) then if isObjectInACLGroup ( "user.".. accName, aclGetGroup ( "Anbu" ) ) then setPlayerTeam ( thePlayer, team ) setPlayerNametagColor ( thePlayer, 225, 0, 0 ) else outputChatBox ( "Usted no es Anbu!", thePlayer ) end end end addCommandHandler ( "itac", criminal ) Link to comment
Nicolas ECM Posted March 17, 2014 Author Share Posted March 17, 2014 thanks I doubt most could add any player acl group through a command? Link to comment
Spajk Posted March 17, 2014 Share Posted March 17, 2014 It is possible with this function: https://wiki.multitheftauto.com/wiki/AclGroupAddObject Link to comment
Nicolas ECM Posted March 17, 2014 Author Share Posted March 17, 2014 thanks I had not seen 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