NPC problem...
#1

Ok, i made an NPC now when it spawns it picks the first team which is found at "OnPlayerRequestClass", now as made a team balancer, that will mess things up, now how to not let the npc go through requestplayerclass, and spawn directly as it connects?
Reply
#2

Check if the playerid is a NPC in OnPlayerRequestClass and return 1.
Reply
#3

pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
    if(IsPlayerNPC(playerid))
    {
        return 1;
    }
    else {
        //code
    }
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)