• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Pawn] i have a error
#4
Code:
#define CheckLoop(%0) for(new %0; %0 <= Connects;%0) if(IsPlayerConnected(%0))

new bool:gGlPrivados[MAX_PLAYERS] = false; // Gl Privados is disabled defaultly.

EnableGlPrivados(playerid)
{
gGlPrivados[playerid] = true;
SendClientMessage(playerid, -1, "GL Enabled.");
}

DisableGlPrivados(playerid)
{
gGlPrivados[playerid] = false;
SendClientMessage(playerid, -1, "GL Disabled.");
}

CMD:togglegl(playerid, params[])
{
if (gGlPrivados[playerid] == true)
DisableGlPrivados(playerid);
else
EnableGlPrivados(playerid);
return 1;
}

public OnPlayerText(playerid, text[])
{
// rest of your code
CheckLoop(i)
{
if (gGlPrivados[i] == true)
{
new string[132];
format(string, sizeof(string), "PlayerID: %d | Text: %s", playerid, text[0]);
SendClientMessage(i, 0xFF0000FF, string);
}
}
return 0;
}
I didn't test this at all, and also I have no clue what you are trying to achieve, so keep this in mind.
  Reply


Messages In This Thread
i have a error - by Nicolas_Belic - 2021-02-20, 01:27 PM
RE: i have a error - by LinesinRows - 2021-02-20, 05:34 PM
RE: i have a error - by Nicolas_Belic - 2021-02-20, 07:37 PM
RE: i have a error - by destiezk - 2021-02-20, 08:53 PM
RE: i have a error - by LinesinRows - 2021-02-20, 08:55 PM
RE: i have a error - by daddy. - 2021-02-20, 08:59 PM
RE: i have a error - by Nicolas_Belic - 2021-02-20, 09:19 PM
RE: i have a error - by daddy. - 2021-02-20, 09:23 PM
RE: i have a error - by Nicolas_Belic - 2021-02-20, 09:32 PM
RE: i have a error - by daddy. - 2021-02-20, 10:21 PM
RE: i have a error - by Nicolas_Belic - 2021-02-21, 01:38 AM
RE: i have a error - by arber - 2021-02-20, 11:29 PM

Forum Jump: