22.08.2016, 13:50
Quote:
BUMP.
Here is the code I use, headshot works but even after disabled and works only for id 0. pawn Код:
|
PHP код:
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(activeheadshot == 1)
{
headshot[i] = 1;
dini_IntSet("server.ini","headshot", activeheadshot);
SendClientMessage(playerid, COLOR_ORANGE, "Vous avez activй le headshot pour tout le monde.");
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "L'admin %s a activй les headshots. (Eagle, Rifle, Sniper)", sendername);
SendClientMessageToAll(COLOR_WHITE, string);
format(string, sizeof(string), "~w~HEADSHOT ACTIVE");
GameTextForAll(string, 5000, 3 );
}
if(activeheadshot == 0)
{
headshot[i] = 0;
dini_IntSet("server.ini","headshot", activeheadshot);
GetPlayerName(playerid, sendername, sizeof(sendername));
SendClientMessage(playerid, COLOR_ORANGE, "Vous avez dйsactivй le headshot pour tout le monde.");
format(string, sizeof(string), "Ladmin %s a dйsactivй les headshots.", sendername);
SendClientMessageToAll(COLOR_WHITE, string);
format(string, sizeof(string), "~r~HEADSHOT DESACTIVE");
GameTextForAll(string, 5000, 3);
}
}
return 1;}
*use zcmd instead of strcmp
*use foreach for looping through players
*use sql saving system.