PHP код:
/* Credits: DonSpeed */
#include a_samp
#define MAX_BALACE 2
#define LARANJA 0xFF6600AA
new Float:Balanca[MAX_BALACE][3]={
{00.00,00.00,00.00},
{00.00,00.00,00.00}
};
new bool:DCheck[MAX_PLAYERS] = false;
forward DonSpeed(playerid);
public DonSpeed(playerid)
{
if(!IsPlayerInAnyVehicle(playerid))return 1;
for(new i = 0; i < sizeof(MAX_BALACE); i++)
{
if(!IsPlayerInRangeOfPoint(playerid, 3.0,Balanca[i][0], Balanca[i][1], Balanca[i][2]))return 1;// CORRIGIR PRECISAO
if(APlayerData[playerid][Overloaded] == true && DCheck[playerid] == true)// TROQUE O OVERLOAD POR SUA DEFINE
{
new DS[80], DName[MAX_PLAYER_NAME];GetPlayerName(playerid, DName, sizeof(DName));
format(DS,sizeof(DS),"{00FF00}O jogador %s esta com sobre-carga [Meta: Multa-lo].", DName);
Police_SendMessage(Msg);
GameTextForPlayer(playerid,"Vocк foi pego pela balanзa, os policiais foram orientados a multa-lo.", 3000, 5);
SetPlayerColor(playerid, LARANJA);
GetPlayerWantedLevel(playerid, + 1);
TogglePlayerControllable(playerid, 0);
DCheck[playerid] = false;
SetTimerEx("DLiberar", 1000*30, false, "i", playerid);
SetTimerEx("DCongelar", 1000*3, false, "i", playerid);
}else GameTextForPlayer(playerid,"Vocк estб а beira de cargas!", 3000, 5);
}
return 1;
}
forward DCongelar(playerid);
public DCongelar(playerid)return TogglePlayerControllable(playerid, 1);
forward DLiberar(playerid);
public DLiberar(playerid)return DCheck[playerid] = true;