Hello everyone, Here I created bots but the problem is that a time one of the stops and goes on the roof of the bus, while another bus works very well, as if the other became invisible when I do /goto ID can be seen moving but invisibly!
Код:
#include <a_samp>
new Bus_1;
new Bus_2;
public OnGameModeInit()
{
// NPCS
ConnectNPC("Bus_1","bus");
ConnectNPC("Bus_2","bus2");
Bus_1 = AddStaticVehicle(431,-1988.0057,116.6116,27.6411,0.6686,75,59); // bus1
Bus_2 = AddStaticVehicle(431,-2242.7822,523.9103,35.2758,359.7419,75,59); // bus1
return 1;
}
public OnPlayerSpawn(playerid)
{
if(!IsPlayerNPC(playerid)) return 0; // We only deal with NPC players in this script
new playername[64];
GetPlayerName(playerid,playername,64);
if(!strcmp(playername,"Bus_1",true)) {
PutPlayerInVehicle(playerid, Bus_1, 0);
SetSpawnInfo( playerid, 0, 255, 1958.33, 1343.12, 15.36, 269.15, 0, 0, 0, 0, 0, 0 );
ShowPlayerMarkers(0);
}
else if(!strcmp(playername,"Bus_2",true)) {
PutPlayerInVehicle(playerid, Bus_2, 0);
SetSpawnInfo( playerid, 0, 255, 1958.33, 1343.12, 15.36, 269.15, 0, 0, 0, 0, 0, 0 );
ShowPlayerMarkers(0);
}
return 1;
}