Jump to content

help with easy script


panos144

Recommended Posts

hi guys why this working with all players and no only with Squards team?

  
function unwanted (player) 
setPlayerWantedLevel( source,0 ) 
if getPlayerTeam(player) == getTeamFromName("Squards") then 
end 
end 
addEventHandler ( "onPlayerSpawn", root, unwanted ) 

Link to comment
you setted 'source' instead of 'player'
function unwanted (player) 
if getPlayerTeam(player) == getTeamFromName("Squards") then 
setPlayerWantedLevel( player,0 ) 
end 
end 
addEventHandler ( "onPlayerSpawn", root, unwanted ) 

Wrong.

function unwanted () 
    if getPlayerTeam(getTeamName(source)) == getTeamFromName("Squards") then 
        setPlayerWantedLevel( source,0 ) 
    end 
end 
addEventHandler ( "onPlayerSpawn", root, unwanted ) 

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