Bzz335 Posted February 5, 2014 Posted February 5, 2014 Hello,need help. addEventHandler("onPlayerLogin",getRootElement(), function(player) local tp = getPlayerTeam(source) accountName = getAccountName(getPlayerAccount(source)) if tp~=nil and ( isObjectInACLGroup ( "user."..accountName, aclGetGroup ( "Admin" ) )) then setPlayerTeam(source,staff) setPlayerSkin(source,217) outputChatBox("Welcome to the Staff team!",source,153,255,153) outputDebugString ( "Staff: " .. getPlayerName(source) .. " joined the Staff Team.",3,255,215,153) end end ) So,if tp(team) is nil(He isnt in team) and player in ACL group "Admin" then... Please,help.
Castillo Posted February 5, 2014 Posted February 5, 2014 addEventHandler ( "onPlayerLogin",getRootElement(), function ( _, account ) local tp = getPlayerTeam ( source ) local accountName = getAccountName ( account ) if ( not tp and isObjectInACLGroup ( "user.".. accountName, aclGetGroup ( "Admin" ) ) ) then setPlayerTeam ( source, staff ) setElementModel ( source, 217 ) outputChatBox ( "Welcome to the Staff team!", source, 153, 255, 153 ) outputDebugString ( "Staff: ".. getPlayerName ( source ) .." joined the Staff Team.", 3, 255, 215, 153 ) end end )
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