Jump to content

[HELP]Criminal


MasKPro

Recommended Posts

Posted

i think it maybe rubbish as its my first script.. Hope u guys help me with the problem

(SetPlayerTeam(Criminal(getPlayerTeam(source)) 
end 
end 
addCommandHandler("criminal", getRootElement(),setplayerteam) 
  
     

Posted

you have to start the script with a "function name ()" also command handler doesn't need a "getRootElement()" only the command and the function's name

it goes like this

  
function teamTest () 
 local playerTeam = getPlayerTeam ( source )     
local team = getTeamFromName ( "Criminal" )  
 setPlayerTeam ( source, team ) 
end 
addCommandHandler("criminal", teamTest ) 

Posted
you have to start the script with a "function name ()" also command handler doesn't need a "getRootElement()" only the command and the function's name

it goes like this

  
function teamTest () 
 local playerTeam = getPlayerTeam ( source )     
local team = getTeamFromName ( "Criminal" )  
 setPlayerTeam ( source, team ) 
end 
addCommandHandler("criminal", teamTest ) 

Thanks @Price.

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