pawn Код:
if(strcmp(cmd, "/roubarcarga", true) == 0)
{
if(missell[playerid] == 1)
{
SendClientMessage(playerid, COLOR_GREY, "Vocк jб roubou carga espere 1 hora para roubar novamente!");
return 1;
}
new vehicleid = GetPlayerVehicleID(playerid);
if(vehicleid == 482)
{
if(PlayerToPoint(10.0, playerid,-1115.1510,-1637.5106,76.3672))
{
if(PlayerInfo[playerid][pLider] == 19 || PlayerInfo[playerid][pMembro] == 19 || PlayerInfo[playerid][pLider] == 20 || PlayerInfo[playerid][pMembro] == 20 || PlayerInfo[playerid][pLider] == 24 || PlayerInfo[playerid][pMembro] == 24 || PlayerInfo[playerid][pLider] == 25 || PlayerInfo[playerid][pMembro] == 25)
{
SetTimerEx("rouboumats", 1000*60*5, false, "i", playerid);
}
}
}
else
{
return SendClientMessage(playerid, Cinza, "Vocк nгo estб em um Burrito");
}
return 1;
}
forward rouboumats(playerid);
public rouboumats(playerid)
{
PlayerInfo[playerid][pMats] += 1000;
GetPlayerName(playerid,sendername,sizeof(sendername));
format(string, sizeof(string), " O bandido %s roubou a carga de armas.", sendername, playerid);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
missell[playerid] = 1;
SetTimerEx("misel",3600000,0,"d",playerid);
new string20[100];
format(string20, sizeof(string20), "Texto");
SendOrg16Message(COLOR_LIGHTBLUE, string20, 1);
SendOrg1Message(COLOR_LIGHTBLUE, string20, 1);
return 1;
}
forward SendOrg16Message(COLOR,const string[], level);
public SendOrg16Message(COLOR,const string[], level)
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(PlayerInfo[i][pMembro] == 16 || PlayerInfo[i][pLider] == 16)
{
SendClientMessage(i, COLOR, string);
}
}
}
return 1;
}
forward SendOrg1Message(COLOR,const string[], level);
public SendOrg1Message(COLOR,const string[], level)
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(PlayerInfo[i][pMembro] == 1 || PlayerInfo[i][pLider] == 1)
{
SendClientMessage(i, COLOR, string);
}
}
}
return 1;
}
Obs: Adaptei algumas coisas do meu sistema entгo faзa do seu jeito olhando ele!