if(strcmp(cmd,"/terminais",true)==0)
{
if(IsPlayerConnected(playerid))
{
new Veh = GetPlayerVehicleID(playerid);
if(!IsAOniCar(Veh))
{
SendClientMessage(playerid, COLOR_GREY, " Voce nгo estб em um фnibus!");
return true;
}
if(PlayerInfo[playerid][pEmprego] == 9)
{
if(TransportDuty[playerid] > 0)
{
if(TransportDuty[playerid] == 2)
{
BusDrivers -= 1;
}
TransportDuty[playerid] = 0;
format(string, sizeof(string), "* Voce estб de folga e recebeu R$%d.", TransportMoney[playerid]);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
GivePlayerMoney(playerid, TransportMoney[playerid]);
ConsumingMoney[playerid] = 1; TransportValue[playerid] = 0; TransportMoney[playerid] = 0;
return true;
}
else
{
BusDrivers += 1; TransportDuty[playerid] = 2; TransportValue[playerid] = 100;
format(string, sizeof(string), "Motorista de onibus %s estб em serviзo, Corrida: R$100 - Vб para o terminal mais prуximo", PlayerName(playerid));
OOCNews(TEAM_GROVE_COLOR,string);
SendClientMessage(playerid, COLOR_RED,"Vocк comeзou o circuito, siga os checkpoints atй finalizar a viajem");
SendClientMessage(playerid, COLOR_RED,"Vocк receberб R$50 a cada checkpoint que passar.");
SendClientMessage(playerid, COLOR_RED,"USE: /terminais novamente para parar o serviзo");
SetPlayerCheckpoint(playerid, 1369.0927,-1736.0730,13.4787,8.0);
gPlayerTerminal[playerid] = 1;
}
}
else
{
SendClientMessage(playerid, COLOR_GREY,"Vocк nгo й um motorista de фnibus.");
}
}
return true;
}
{ if (gPlayerTerminal[playerid] == 13) { PlayerPlaySound(playerid, 1055, 0.0, 0.0, 0.0); TransportMoney[playerid] += 3900; DisablePlayerCheckpoint(playerid); gPlayerTerminal[playerid] = 0; } else { new conta; conta = gPlayerTerminal[playerid]*300; format(gstring,sizeof(gstring), "Vocк encerrou seu serviзo de фnibus e ganhou R$%d.", conta-300); SendClientMessage(playerid, COLOR_LIGHTRED, gstring); PlayerPlaySound(playerid, 1055, 0.0, 0.0, 0.0); TransportMoney[playerid] += conta-300; DisablePlayerCheckpoint(playerid); gPlayerTerminal[playerid] = 0; } return 1; } |
if (gPlayerTerminal[playerid] == 1)
{
PlayerPlaySound(playerid, 1055, 0.0, 0.0, 0.0);
TransportMoney[playerid] += 3900;
DisablePlayerCheckpoint(playerid);
gPlayerTerminal[playerid] = 0;
}
else
{
static conta;
conta = gPlayerTerminal[playerid]*300;
format(gstring,sizeof(gstring), "Vocк encerrou seu serviзo de фnibus e ganhou R$%d.", conta-300);
SendClientMessage(playerid, COLOR_LIGHTRED, gstring);
PlayerPlaySound(playerid, 1055, 0.0, 0.0, 0.0);
TransportMoney[playerid] += conta-300;
DisablePlayerCheckpoint(playerid);
gPlayerTerminal[playerid] = 0;
}
return 1;
}