i took this from gl_npcs filterscript as an example
pawn Код:
public OnPlayerSpawn(playerid)
{
if(!IsPlayerNPC(playerid)) return 1; // We only deal with NPC players in this script
new playername[64];
GetPlayerName(playerid,playername,64);
if(!strcmp(playername,"TrainDriverLV",true)) {
PutPlayerInVehicle(playerid,1,0);
SetPlayerColor(playerid,0xFFFFFFFF); // if you dont want them to be visible on map remove this line(s)
// or change this color to whatever colour you want them to be
}
else if(!strcmp(playername,"TrainDriverSF",true)) {
PutPlayerInVehicle(playerid,5,0);
SetPlayerColor(playerid,0xFFFFFFFF);
}
else if(!strcmp(playername,"TrainDriverLS",true)) {
PutPlayerInVehicle(playerid,9,0);
SetPlayerColor(playerid,0xFFFFFFFF);
}
else if(!strcmp(playername,"PilotLV",true)) {
PutPlayerInVehicle(playerid,13,0);
SetPlayerColor(playerid,0xFFFFFFFF);
}
else if(!strcmp(playername,"PilotSF",true)) {
PutPlayerInVehicle(playerid,14,0);
SetPlayerColor(playerid,0xFFFFFFFF);
}
else if(!strcmp(playername,"PilotLS",true)) {
PutPlayerInVehicle(playerid,15,0);
SetPlayerColor(playerid,0xFFFFFFFF);
}
else if(!strcmp(playername,"TestIdleDriver",true)) {
PutPlayerInVehicle(playerid,43,0);
SetPlayerColor(playerid,0xFFFFFFFF);
}
else if(!strcmp(playername,"TaxiTest",true)) {
PutPlayerInVehicle(playerid,968,0);
SetPlayerColor(playerid,0xFFFFFFFF);
}
return 1;
}