23.05.2012, 13:21
http://pastebin.com/QB8dDGBX
I know thats horribly scripted, but what I want to do his, when he uses that,
I want him to be teleported to the closest human "Team[playerid] = HUMAN", even tho he has zombies around him.
But with that code, if a zombie is near him, the var id just remains -1.
I know whats the problem ,but I don't know how to fix it.
if(Team[id2] == ZOMBIE) continue; <- Thats the problem, yet I don't know any other solution.
I know thats horribly scripted, but what I want to do his, when he uses that,
I want him to be teleported to the closest human "Team[playerid] = HUMAN", even tho he has zombies around him.
But with that code, if a zombie is near him, the var id just remains -1.
I know whats the problem ,but I don't know how to fix it.
if(Team[id2] == ZOMBIE) continue; <- Thats the problem, yet I don't know any other solution.