08.07.2013, 21:32
Scroll Right and see the problem..
pawn Код:
CMD:onduty(playerid, params[])
{
if(PlayerInfo[playerid][pJob] != JOB_TAXI && PlayerInfo[playerid][pVIPJob] != JOB_TAXI) return SendClientMessage(playerid, COLOR_GREY, "You are not a taxi driver.");
{
if(PlayerInfo[playerid][pTaxDuty] == 1) return SendClientMessage(playerid, COLOR_WHITE, "You cant go on duty twice use(/offduty)");
new string[128];
if(!IsPlayerLoggedIn(playerid)) return SendClientMessage(playerid, COLOR_GREY, "You need to login first before using any command."); // This dont show either
if(!IsTaxiVehicle(GetPlayerVehicleID(playerid))) return SendClientMessage(playerid, COLOR_GREY, "You must be in an taxi vehicle to use this command."); // This MSG not showing which means i can do the cmd anywhere
foreach(Player, i)
{
if(IsPlayerLoggedIn(i))
{
format(string, sizeof(string), "TaxiAd: Taxi driver %s has went on-duty as a taxi driver. If you need a taxi call the company. ((/service taxi)) ", RPN(playerid));
SendClientMessage(i, TEAM_GROVE_COLOR, string);
format(string, sizeof(string), "Anyone enters your taxi car after arriving to the place they want, request the money by Roleplaying.");
SendClientMessage(playerid, COLOR_YELLOW, string);
SetPlayerColor(playerid, TCOLOR_YELLOW);
PlayerInfo[playerid][pTaxDuty] = 1;
}
}
}
return 1;
}