Jump to content

[SOLVED]Permanent Team color


quality

Recommended Posts

Hi guys. I have a simple Admin team on spawn script created and I wanted to know how do I add a perm color to the team. To be more specific, what is the script in order for me to log into my server every day and get the same color for my in-game name?

Below is the simple admin on spawn team, how do I add perm color to each admin that spawns in that team? I hope you understand,

function createAdminTeamOnStart (Admin) 
    AdminTeam = createTeam ( "Admin", 131, 139, 131 )-- create a new team and name it 'Admin' 
end 
addEventHandler("onResourceStart", resourceRoot, createAdminTeamOnStart) -- add an event handler 
  
function setAdminTeam() 
if isObjectInACLGroup("user."..getAccountName(getPlayerAccount(source)), aclGetGroup("Admin")) then -- if he is admin 
   setPlayerTeam(source, AdminTeam) -- set him to admin team 
   end 
end 
addEventHandler("onPlayerLogin",getRootElement(),setAdminTeam) -- add an event handler 
  

Edited by Guest
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...