Skip to content

Instantly share code, notes, and snippets.

@Dronr
Created July 16, 2015 19:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Dronr/a242262855f7d2b10747 to your computer and use it in GitHub Desktop.
Save Dronr/a242262855f7d2b10747 to your computer and use it in GitHub Desktop.
CMD:m(playerid, params[])
{
return cmd_megaphone(playerid, params);
}
CMD:megaphone(playerid, params[])
{
if(!AcceptWrite(playerid)) return 1;
if(sscanf(params, "s[124]",params[0])) return SendClientMessage(playerid, COLOR_WHITE, "Введите: (/m)egaphone [текст]");
new string[124];
switch(pData[playerid][Member])
{
case 1,2,3:
{
if(GetVehicleModel(GetPlayerVehicleID(playerid)) != 523 && GetVehicleModel(GetPlayerVehicleID(playerid)) != 427 && GetVehicleModel(GetPlayerVehicleID(playerid)) != 596 && GetVehicleModel(GetPlayerVehicleID(playerid)) != 597 && GetVehicleModel(GetPlayerVehicleID(playerid)) != 598 ) return SendClientMessage(playerid, COLOR_WHITE, "Вы не состоите в полиции");
format(string, sizeof(string), "{{ Офицер %s: %s }}",getName(playerid),params[0]);
ProxDetector(80.0, playerid, string,COLOR_YELLOW,COLOR_YELLOW,COLOR_YELLOW,COLOR_YELLOW,COLOR_YELLOW);
}
case 12:
{
if(GetPlayerVehicleID(playerid) >= fbicar[0] && GetPlayerVehicleID(playerid) <= fbicar[7])
{
format(string, sizeof(string), "{{ Агент FBI %s: %s }}",getName(playerid),params[0]);
ProxDetector(80.0, playerid, string,COLOR_YELLOW,COLOR_YELLOW,COLOR_YELLOW,COLOR_YELLOW,COLOR_YELLOW);
}
}
}
return true;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment