Vezi mesaje fără răspuns | Vezi subiecte active Acum este Mar Apr 28, 2026 6:34 am



Răspunde la subiect  [ 2 mesaje ] 
chat_manager.amxx - Impotriva botilor spam 
Autor Mesaj
Sef de echipa
Avatar utilizator

Membru din: Vin Mai 01, 2015 11:27 pm
Mesaje: 901
Localitate: Germania
Steam ID: gunner_game
Yahoo ID: vest_alecsoviki
Server Preferat: Cs.Playcs.ro
Detinator Server: Cs.Playcs.ro
Zm.Playcs.ro
Respawn.Playcs.ro
GunGame.Playcs.ro
Acest plugin va ajuta sa setati o parola pe chatul de pe server, astfel boti nu vor mai putea sa trimita un flux mic sau mare de mesaje pe serverul dumneavoastra.

Download link sma+amxx

Mai jos, un sursa puteti sa va setati ce parola doriti pe chat. Parola actuala este playcs


Cod:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <amxmisc>

#define PLUGIN "No bot chat"
#define VERSION "0.2"
#define AUTHOR "rider"
//parola pentru chat
//#define passwd "playcs"

new bool:g_allowed[33]
new SayText
new randPasswd[6]

public plugin_init() {
   register_plugin(PLUGIN, VERSION, AUTHOR)   
   register_clcmd("say", "sayHandle")
   register_clcmd("say_team", "sayHandle")
   SayText = get_user_msgid("SayText")
}

public client_connect(id) {
   g_allowed[id] = false

}

public client_putinserver(id){
   //alegem o parola random
   new iRand = random_num(1,5)
   switch(iRand)
   {
      case 1:
      {
         copy(randPasswd, 6, "playcs")
      }
      case 2:
      {
         copy(randPasswd, 6, "playcs")
      }
      case 3:
      {
         copy(randPasswd, 6, "playcs")
      }
      case 4:
      {
         copy(randPasswd, 6, "playcs")
      }
      case 5:
      {
         copy(randPasswd, 6, "playcs")
      }
   }
}
public client_disconnect(id) {
   g_allowed[id] = false
}

public sayHandle(id) {
   new said[192]
   read_args(said, 191)
   if (contain(said, randPasswd) != -1 && !g_allowed[id])
   {
      g_allowed[id] = true;
      client_printcolor(id, "!g[!yPlaycs Bot!g] !yAi primit permisiunea de a folosi chatul")
      return PLUGIN_HANDLED;
   }
   if(!g_allowed[id])
   {
      client_printcolor(id, "!g[!yPlaycs Bot!g] !yScrie !t%s !ypentru a putea folosi chatul.",randPasswd)
      return PLUGIN_HANDLED;
   }
   return PLUGIN_CONTINUE;
}
//chat color
stock client_printcolor(const id, const input[], any:...)
{
   new count = 1, players[32]
   static msg[191]
   vformat(msg, 190, input, 3)
   
   replace_all(msg, 190, "!g", "^4") // Green Color
   replace_all(msg, 190, "!y", "^1") // Default Color
   replace_all(msg, 190, "!t", "^3") // Team Color
   
   if (id) players[0] = id; else get_players(players, count, "ch")
   {
      for ( new i = 0; i < count; i++ )
      {
         if ( is_user_connected(players[i]) )
         {
            message_begin(MSG_ONE_UNRELIABLE, SayText, _, players[i])
            write_byte(players[i]);
            write_string(msg);
            message_end();
         }
      }
   }
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1033\\ f0\\ fs16 \n\\ par }
*/

_________________
facebook.com/Playcs.ro - Like Facebook Page
steamcommunity.com/groups/wwwplaycsro - Alaturate grupului nostru


Mar Iun 09, 2015 11:59 pm
Profil Trimiteţi mesaj privat E-mail YIM WWW
Membru
Avatar utilizator

Membru din: Vin Sep 18, 2015 2:47 pm
Mesaje: 1
nu merge descarcarea,nu stiu de ce.
ma puteti ajuta?
asta imi apare cand dau click pe link.
http://i61.tinypic.com/2zgyptf.png


Vin Sep 18, 2015 2:51 pm
Profil Trimiteţi mesaj privat E-mail
Afişează mesajele din ultimele:  Sortează după  
Răspunde la subiect   [ 2 mesaje ] 

Cine este conectat

Utilizatorii ce navighează pe acest forum: Niciun utilizator înregistrat şi 2 vizitatori


Nu puteţi scrie subiecte noi în acest forum
Nu puteţi răspunde subiectelor din acest forum
Nu puteţi modifica mesajele dumneavoastră în acest forum
Nu puteţi şterge mesajele dumneavoastră în acest forum
Nu puteţi publica fişiere ataşate în acest forum

Căutare după:
Mergi la:  
Furnizat de phpBB® Forum Software © phpBB Group
Designed by ST Software.
Translation/Traducere: phpBB România
phpBB SEO