18.02.2011, 23:28
as the title says the npcs I make join then leave for some unknown reason...
here is the code I put under onplayerspawn:
any help?
here is the code I put under onplayerspawn:
Код:
if(IsPlayerNPC(playerid)) { new npcname[MAX_PLAYER_NAME]; GetPlayerName(playerid, npcname, sizeof(npcname)); if(!strcmp(npcname, "Bus_Driver", true)) { PutPlayerInVehicle(playerid, MyFirstNPCVehicle, 431); } return 1; } if(IsPlayerNPC(playerid)) { new npcname[MAX_PLAYER_NAME]; GetPlayerName(playerid, npcname, sizeof(npcname)); if(!strcmp(npcname, "Crazy_Train_Driver", true)) { PutPlayerInVehicle(playerid, MyFirstNPCVehicle, 538); } return 1; } if(IsPlayerNPC(playerid)) { new npcname[MAX_PLAYER_NAME]; GetPlayerName(playerid, npcname, sizeof(npcname)); if(!strcmp(npcname, "Busdriver", true)) { PutPlayerInVehicle(playerid, NPCBus, 0); SetPlayerSkin(playerid, 255); ResetPlayerWeapons(playerid); } return 1; } if(IsPlayerNPC(playerid)) { new npcname[MAX_PLAYER_NAME]; GetPlayerName(playerid, npcname, sizeof(npcname)); if(!strcmp(npcname, "Helicopter", true)) { PutPlayerInVehicle(playerid, MyFirstNPCVehicle, 425); } return 1; }