Jump to content

Team


Recommended Posts

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
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

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...