22.02.2011, 18:04
Heey guys
I am busy with fun stuff for NPC.
Now I want that when a npc enters a racecheckpoint that he gets kicked and the car gets removed.
Now the car gets removed, but the NPC does not gets kicked
This is my code:
Thanks
I am busy with fun stuff for NPC.
Now I want that when a npc enters a racecheckpoint that he gets kicked and the car gets removed.
Now the car gets removed, but the NPC does not gets kicked
This is my code:
pawn Код:
public OnPlayerEnterRaceCheckpoint(playerid)
{
if(IsPlayerInRangeOfPoint(playerid,20,2432.2124,1128.8608,10.6719))
{
DestroyVehicle(Taxi1);
new npcname[MAX_PLAYER_NAME];
GetPlayerName(playerid, npcname, sizeof(npcname));
if(IsPlayerNPC(playerid))
{
if(!strcmp(npcname, "NPC6", true))
{
Kick(playerid);
}
}
}
return 1;
}
![Smiley](images/smilies/smile.png)