Jump to content

Ranks


mint3d

Recommended Posts

ok i have made ranks but when i look at tab there is Ranks but it dont say like Owner

      
    function setACL(player) 
        local Owner = "Owner" 
        if isObjectInACLGroup ( "user." ..getAccountTeam(getPlayerAccount(player)) , aclGetGroup ( "Admin" ) ) then 
        setElementData ( player, "ACL", admin ) 
  
        end 
    end 
      
    function timer() 
        setTimer( setACL, 1000, 1, source ) 
    end 
    addEventHandler("onPlayerLogin", getRootElement(), timer) 
    addEventHandler("onPlayerJoin", getRootElement(), timer) 

Link to comment

-- # Server Side 
function setACL(player) 
        local Owner = "Owner" 
        if isObjectInACLGroup ( "user." ..getAccountName(getPlayerAccount(player)) , aclGetGroup ( "Admin" ) ) then 
        setElementData ( player, "ACL", Owner ) 
        end 
    end 
     
function timer() 
        setTimer( setACL, 1000, 1, source ) 
    end 
    addEventHandler("onPlayerLogin", getRootElement(), timer) 
    addEventHandler("onPlayerJoin", getRootElement(), timer) 

That's what are you trying to do ?

Link to comment

No i have Ranks in tab but i cant see the "Owner" bit i added the ranks bit also

  exports.scoreboard:scoreboardAddColumn("Ranks") 
      
function setACL(player) 
        local Owner = "Owner" 
        if isObjectInACLGroup ( "user." ..getAccountName(getPlayerAccount(player)) , aclGetGroup ( "Admin" ) ) then 
        setElementData ( player, "ACL", Owner ) 
        outputChatBox( Owner ) 
        end 
    end 
    
function timer() 
        setTimer( setACL, 1000, 1, source ) 
    end 
    addEventHandler("onPlayerLogin", getRootElement(), timer) 
    addEventHandler("onPlayerJoin", getRootElement(), timer) 

Link to comment
exports.scoreboard:scoreboardAddColumn ( "Ranks" ) 
  
addEventHandler ( "onPlayerLogin", getRootElement(), 
    function ( _, account ) 
        if isObjectInACLGroup ( "user.".. getAccountName ( account ), aclGetGroup ( "Admin" ) ) then 
            setElementData ( source, "Ranks", "Owner" ) 
        end 
    end 
) 

Link to comment

Sorry but i added this and not work

function 
        addEventHandler ( "onPlayerLogin", getRootElement(), 
        function ( _, account ) 
        if isObjectInACLGroup ( "user.".. getAccountName ( account ), aclGetGroup ( "Moderator" ) ) then 
            setElementData ( source, "Ranks", "New Staff" ) 
         
        end 
    end 
) 

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