Jump to content

getplayeraccount error


Monty

Recommended Posts

what's wrong?

  
function createFBITeam () 
   ARMYTeam = createTeam ("ARMY", 0, 102, 0) 
end 
addEventHandler ("onResourceStart", resourceRoot, createFBITeam) 
  
function joinARMY() 
local gang = exports [ 'ROADgang' ]:getAccountGang ( getAccountName ( getPlayerAccount ( client ) ) ) --changed source to client (for safety reasons) 
      if ( gang == "ARMY" ) then 
     setPlayerTeam(source,ARMYTeam) 
     local acc = getAccountName( source ) 
      if acc == "stolka" then 
       setElementModel(source,73) 
       esle 
     setElementModel(source,287) 
      giveWeapon ( source, 31, 120 ) 
     setElementData( source, "Occupation", "ARMY", true ) 
     outputChatBox("You are now an ARMY soldier.",source,0,255,0) 
     end 
 end 
end 
addEvent("setARMY", true) 
addEventHandler("setARMY",root,joinARMY) 

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