Jump to content

help me this error


kurubay

Recommended Posts

hey i ve got an error

Bad argument @ 'getPlayerTeam' [Expected player at argument 1, got boolean]

  
function Boss_ini() 
boss=exports [ "slothBot" ]:spawnBot(-451.30627441406,2593.0285644531,48.308349609375,90,boss_skin,0,0,botT,7,"hunting") 
setElementData(boss,"PedExtraHealth",boss_extraH) 
outputChatBox(idioma[12],root) 
triggerClientEvent("CreateNinjaSound",root,boss,"1.mp3") 
madarsT1 = setTimer(bot_app_jutsus,boss_jutsusTimer,0) 
madarsT2 = setTimer(bot_app_jutsusCombo,boss_jutsusTimer2,0) 
setElementData(boss,"Boss",true) 
addEventHandler("onPedWasted",boss,Boss_wasted) 
local x,y,z = getElementPosition(boss) 
local r=getRandomPlayer() 
for i=1,180,18 
do 
local _i = i*(math.pi/180) 
 exports [ "slothBot" ]:spawnBot(math.cos(_i)*8+x,math.sin(_i)*8+y,z,90,115,0,0,getPlayerTeam(r),8,"chasing",boss) ==> error here 
 end 
 for b=180,360,18 
do 
local _b = b*(math.pi/180) 
 exports [ "slothBot" ]:spawnBot(math.cos(_b)*8+x,math.sin(_b)*8+y,z,90,118,0,0,getPlayerTeam(r),4,"chasing",boss) 
 end 
end  
  

Link to comment
  • 2 weeks later...

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