NPC ID
#1

Hey guys, Is it possible to create a NPC which has a ID, so I can test some scripts.
Reply
#2

each NPC has a ID like every player has .. they just dont show up in [TAB] or any server player list
Reply
#3

use onplayerspawn or connect:

pawn Код:
new npcname[MAX_PLAYER_NAME];
        GetPlayerName(playerid, npcname, sizeof(npcname));
        if(!strcmp(npcname, "yourbotnamehere", true))
        {
            yourbotnamevariable = playerid;
            return 1;
        }
that should work, change the botnamevariable to your botvariable, and the name to your bot name
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)