Balkan SA:MP

PAWN skriptanje, gamemodovi, filterskripte, include fajlovi, mape, pluginovi => Razgovor u vezi PAWN - skriptanja => Temu započeo: JuustyGe poslato Oktobar 14, 2010, 21:25:08 POSLE PODNE

Naslov: [Pomoc]Chat
Poruka od: JuustyGe poslato Oktobar 14, 2010, 21:25:08 POSLE PODNE
Kako otkloniti chat odredjenom igracu kao na f7 ili nekako poozite treba mi to
Naslov: Odg: [Pomoc]Chat
Poruka od: Rotcod poslato Oktobar 15, 2010, 09:47:18 PRE PODNE
Cek jer ti hoces da igrac nemoze da pise ni na jedan chat kad ti hoces? to ti je onda cmd mute?


if(strcmp(cmd, "/mute", true) == 0)
{
    if(IsPlayerConnected(playerid))
    {
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /mute [playerid/PartOfName]");
return 1;
}
new playa;
playa = ReturnUser(tmp);
if (PlayerInfo[playerid][pAdmin] >= 1)
{
    if(IsPlayerConnected(playa))
    {
        if(playa != INVALID_PLAYER_ID)
        {
    GetPlayerName(playa, giveplayer, sizeof(giveplayer));
    if(playa != playerid && Untouchable[playa]) return SendClientMessage(playerid, COLOR_GREY, "* You Can't Do this on This player!");
if(PlayerInfo[playa][pMuted] == 0)
{
PlayerInfo[playa][pMuted] = 1;
format(string, sizeof(string), "[ADMIN]: %s Has Muted %s (%d).",sendername,giveplayer,playa);
ABroadCast(COLOR_LIGHTRED,string, 5);
GameTextForPlayer(playa, "~r~Muted by An Administrator!",4000,3);
new y, m, d;
new h,mi,s;
getdate(y,m,d);
gettime(h,mi,s);
format(string,sizeof(string), "(%d/%d/%d)[%d:%d:%d] %s Has Muted %s",d,m,y,h,mi,s,sendername,giveplayer);
MuteLog(string);
}
else
{
PlayerInfo[playa][pMuted] = 0;
format(string, sizeof(string), "[ADMIN]: %s Has Un-Muted %s (%d).",sendername,giveplayer,playa);
ABroadCast(COLOR_LIGHTRED,string, 5);
GameTextForPlayer(playa, "~g~Unmuted by An Administrator!",4000,3);
new y, m, d;
new h,mi,s;
getdate(y,m,d);
gettime(h,mi,s);
format(string,sizeof(string), "(%d/%d/%d)[%d:%d:%d] %s Has UnMuted %s",d,m,y,h,mi,s,sendername,giveplayer);
MuteLog(string);
}
}
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, "** you are not authorized to use that command!");
}
}
return 1;
}
Naslov: Odg: [Pomoc]Chat
Poruka od: JuustyGe poslato Oktobar 15, 2010, 13:10:58 POSLE PODNE
to ti je ono na pocetku kada id eonaj tut za pravila i to eh tad ocu da nema nista na chatu
Naslov: Odg: [Pomoc]Chat
Poruka od: Dr.Ivex → ♫ poslato Oktobar 15, 2010, 13:23:04 POSLE PODNE

forward ClearChat(playerid);
public ClearChat(playerid)
{
   if (IsPlayerConnected(playerid))
   {
      for(new i=0; i<30; i++)
      {
         SendClientMessage(playerid, COLOR_WHITE, " ");
      }
   }
   return 1;
}
Naslov: Odg: [Pomoc]Chat
Poruka od: JuustyGe poslato Oktobar 15, 2010, 17:00:11 POSLE PODNE
Citat: [ST]ivex â†' ♫ poslato Oktobar 15, 2010, 13:23:04 POSLE PODNE

forward ClearChat(playerid);
public ClearChat(playerid)
{
   if (IsPlayerConnected(playerid))
   {
      for(new i=0; i<30; i++)
      {
         SendClientMessage(playerid, COLOR_WHITE, " ");
      }
   }
   return 1;
}

jest ali moze svak ziv pisat onda