Un anti-flood !

Soyez le premier à donner votre avis sur cette source.

Snippet vu 9 055 fois - Téléchargée 26 fois

Contenu du snippet

Héhé :p

Source / Exemple :


alias block.join {
  window -c @Multi. $+ $gettok($3-,4,32) $+ . $+ $1
  aline -hp $colour(info2)  $2 *** $gettok($3-,4,32) : $rem.double($gettok($3-,5-,32))
  aline -hp $colour(info2)  $2 
}

alias show.whois.mask { 
  aline -hp  $colour(Whois) $active *** $gettok($1-,4,32)   $gettok($1-,5,32) $+ @ $+ $gettok($1-,6,32) : $gettok($1-,7-,32)  
  var %multi.country = $readini $scriptdir $+ countries.ini countries $gettok($gettok($1-,6,32),-1,46)
  if (%multi.country != $null) { aline -hp  $colour(info) $active *** country : $gettok(%multi.country,2-10,32) ( $+ $gettok(%multi.country,1,32) $+ ) } 
}

alias show.whois.chan { aline -hp  $colour(Whois) $active *** is in channel(s)  $gettok($1-,5-,32) }

alias show.whois.net { aline -hp  $colour(Whois) $active *** connected to server : $gettok($1-,5-,32) }

alias show.whois.IRCop { aline -hp  $colour(info) $active *** $rem.double($gettok($1-,5-,32)) }

alias show.whois.idle { 
  aline -hp  $colour(Whois) $active *** signed on $duration($calc($ctime - $gettok($1-,6,32))) ago 
  aline -hp  $colour(Whois) $active *** has been $duration($gettok($1-,5,32)) idle 
}

alias show.whois.end { 
  aline -hp  $colour(Whois) $active ***  $gettok($1-,4,32)  $gettok($1-,5-,32)  
  aline -hp  $colour(Whois) $active 
}

alias multi.i.isop {
  var %i.isop = %multiserver.op. [ $+ [ $gettok($active,3-,46) ] ] [ $+ . $+ [ $multi.chan ] ]
  if ((%i.isop != $null) && ($mouse.lb)) { return #boss }
}

alias multi.chan { return $gettok($active,2,46) }

alias multi.me.nick { return %multiserver.nick1. [ $+ [ $gettok($active,3-,46) ] ] }

alias listbox { 
  if ($mouse.lb) { return $1- } 
} 

alias chanpop { 
  if ($mouse.lb == $false) { return $1- } 
} 

alias querypop { 
  if (($mouse.lb == $false) && ($left($gettok($active,2,46),1) != $chr(35)) && ($gettok($active,2,46) != status)) { return $1- } 
} 

;multi.echo <message> 
alias multi.echo { 
  var %echo.num = $numtok($1-,32)
  var %echo.i = 1
  var %echo.text
  while  (%echo.i <= %echo.num) {
    %echo.text = %echo.text [ [ $gettok($1-,%echo.i,32) ] ]
    inc %echo.i 1
  }
  echo $colour(own) -a %echo.text 
}

;multi.me <message>
alias multi.me { var %sock.me = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.me PRIVMSG $gettok($active,2,46)  :ACTION $1- $+  | aline -hp $colour(action) * %multiserver.nick1. [ $+ [ $gettok($active,3-,46) ] ]  $1- }

;multi.msg <nickname> <message> or multi.msg <channel> <message>
alias multi.msg { var %sock.msg = multiserver. $+ $gettok($active,3-,46) |  sockwrite -tn %sock.msg PRIVMSG $1  : $2- | aline -hp $colour(own)  $+ $colour(highlight) $+ < $+ %multiserver.nick1. [ $+ [ $gettok($active,3-,46) ] ] $+ >  $+ $colour(own) $+ $2- }

;multi.msg.silent <nickname> <message>
alias multi.msg.silent { var %sock.msg.silent = multiserver. $+ $gettok($active,3-,46) |  sockwrite -tn %sock.msg.silent PRIVMSG $1  : $2- | aline -hp $colour(own) --> $1 - $2- }

;multi.say <message>
alias multi.say { var %sock.say = multiserver. $+ $gettok($active,3-,46) |  sockwrite -tn %sock.say PRIVMSG $gettok($active,2,46)  : $1- | aline -hp $colour(own)  $+ $colour(highlight) $+ < $+ %multiserver.nick1. [ $+ [ $gettok($active,3-,46) ] ] $+ >  $+ $colour(own) $+ $1- }

;multi.quote <command> <parameters>
alias multi.quote { var %sock.quote = multiserver. $+ $gettok($active,3-,46) |  sockwrite -tn %sock.quote $1 : $2-  }

;multi.query <nickname>
alias multi.query {
  if ((@ isin $1) || (+ isin $1)) { var %multi.win.query = @Multi. $+ $rem.double($1) $+ . $+ $gettok($active,3-,46) }
  else { var %multi.win.query = @Multi. $+ $1 $+ . $+ $gettok($active,3-,46) }
  if ($window(%multi.win.query).state == $null) {  window -bek0 %multi.win.query 10 10  500 250 }
  elseif (($window(%multi.win.query).state == minimized) || ($window(%multi.win.query).state == normal)) { window -a %multi.win.query }
}

;multi.ping <nickname>
alias multi.ping { var %sock.ping = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.ping PRIVMSG $1 :PING $ctime  $+  | aline -hp $colour(own) $target -> Ping request on $1 }

;multi.ctcp <nick> <message>
alias multi.ctcp { var %sock.ctcp = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.ctcp PRIVMSG $1 : $+ $2- $+  | aline -hp $colour(ctcp) $target -> $chr(91) $+ $1 $+ $chr(93) - $2- }

;multi.whois <nickname>
alias multi.whois { var %sock.whois = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.whois whois $1 }

;multi.whois.idle <nickname>
alias multi.whois.idle { var %sock.whois.idle = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.whois.idle whois $1 $1 }

;multi.whowas <nickname>
alias multi.whowas { var %sock.whowas = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.whowas whowas $1 }

;multi.who <nickname> or <channel>
alias multi.who { var %sock.who = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.who who $1 }

;multi.nick <new nickname>
alias multi.nick { var %sock.nick = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.nick NICK $1 }

;multi.notice <nickname> <message>
alias multi.notice { var %sock.not = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.not NOTICE $1  : $2-  | aline -hp $colour(own) $target -> $1 - $2- }

;multi.mode <paramaters>
alias multi.mode { var %sock.mode = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.mode MODE $1- }

;multi.kick <nick> <reason>
alias multi.kick {  var %sock.kick = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.kick KICK $1 $2 : $+ $3- }

;multi.invite <channel> <nick>
alias multi.invite { var %sock.inv = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.inv INVITE $1 $2 }

;multi.topic <channel> <topic>
alias multi.topic { var %sock.top = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.top TOPIC $1 : $+ $2- }

;multi.away <msg> 
alias multi.away { var %sock.away = multiserver. $+ $gettok($active,3-,46) | sockwrite -tn %sock.away AWAY : $+ $1- }

;multi.join <channel> 
alias multi.join { 
  if ($left($1,1) == $chr(35) ) { 
    var %sock.join = multiserver. $+ $gettok($active,3-,46) 
    var %multi.win.chan = @Multi. $+ $1 $+ . $+ $gettok($active,3-,46)
    if ($window(%multi.win.chan).state == $null) { set %multiserver.names. [ $+ [ $gettok($active,3-,46) ] ] [ $+ . ] [ $+ [ $1 ] ] [ on ] }
    multi.status.win $gettok($active,3-,46) $1   
    sockwrite -tn %sock.join JOIN $1-  
  }
  else { aline -hp $colour(info2) $active *** Invalid channel name *** }

}

;multi.notify <nick> 
alias multi.notify { 
  if (($left($1,1) == $chr(64)) || ($left($2,1) == +)) { notify $rem.double($1) }
  else { notify $1 }
}

;multi.amsg <message>
alias multi.amsg {
  var %amsg.win.tot = $window(@Multi.#*,0)
  var %amsg.win.i = 1
  while (%amsg.win.i <= %amsg.win.tot) {
    if ($gettok($active,3-,46) == $gettok($window(@Multi.#*,%amsg.win.i),3-,46))  { 
      if ($gettok($window(@Multi.#*,%amsg.win.i),2,46) != status) { multi.msg $gettok($window(@Multi.#*,%amsg.win.i),2,46) $1- }
    }
    inc %amsg.win.i  1
  }
}

;multi ame <message>
alias multi.ame {
  var %ame.win.tot = $window(@Multi.*,0)
  var %ame.win.i = 1
  while (%ame.win.i <= %ame.win.tot) {
    if ($gettok($active,3-,46) == $gettok($window(@Multi.*,%ame.win.i),3-,46))  { 
      if ($gettok($window(@Multi.*,%ame.win.i),2,46) != status) { 
        var %sock.me = multiserver. $+ $gettok($window(@Multi.*,%ame.win.i),3-,46)
        sockwrite -tn %sock.me PRIVMSG $gettok($window(@Multi.*,%ame.win.i),2,46)  : $+ ACTION $1- 
        aline -hp $colour(own) $window(@Multi.*,%ame.win.i)  $+ $colour(action) $+ * %multiserver.nick1. [ $+ [ $gettok($window(@Multi.*,%ame.win.i),3-,46) ] ]  $1-
      }
    }
    inc %ame.win.i  1
  }
}

alias multi.sound {
  if ($2 != $null) { 
    var %multi.sock = multiserver. $+ $gettok($1,3-,46)
    if ($3 != $null) { 
      var %sound.file.exist = $mircdir $+ sounds\ $+ $3
      if ($exists(%sound.file.exist)) { 
        splay -q $3 
        sockwrite -tn %multi.sock PRIVMSG $gettok($1,2,46)   :SOUND $3 $+   
        aline -hp $colour(ctcp) $1 --> $chr(91) $+ SOUND $2 $3 $+ $chr(93)
      }
      else { aline -hp $colour(info2) $target *** /sound : sound file doesn't exist in your sounds folder ***  }
    }
    if ($3 == $null) { 
      var %sound.file.exist = $mircdir $+ sounds\ $+ $2
      if ($exists(%sound.file.exist)) { 
        splay -q $2  
        sockwrite -tn %multi.sock PRIVMSG $gettok($1,2,46)  :SOUND $2 $+  
        aline -hp $colour(ctcp) $1 $chr(91) $+ SOUND $2 $+ $chr(93)
      }
      else { aline -hp $colour(info2) $target *** /sound : sound file doesn't exist in your sounds folder ***  }
    }
  }
  else { aline -hp $colour(info2) $target *** /sound : insufficient parameters ***  }
}

on *:CLOSE:@Multi.*:{ 
  var %multi.resize.win = $readini -n $scriptdir $+ multidata.ini windows $gettok($target,2,46)
  if (%multi.resize.win != $null) { 
    var %multi.win.coord = $window($active).x $window($target).y $window($target).w $window($target).h
    writeini $scriptdir $+ multidata.ini windows $gettok($target,2,46) %multi.win.coord
  } 
}

alias multi.win.pos {
  var %multi.pos = $readini -n $scriptdir $+ multidata.ini pos win
  var %multi.pos.win = $gettok($active,2,46)
  var %multi.pos.i = 1
  var %multi.pos.exist = $false
  while (%multi.pos.i <= $numtok(%multi.pos,32)) {
    if ($gettok(%multi.pos,%multi.pos.i,32) == %multi.pos.win) { %multi.pos.exist = $true | break }
    inc %multi.pos.i 1
  }
  if (%multi.pos.exist == $true) { echo $colour(info) -a *** window %multi.pos.win is already in the list }
  else {
    %multi.pos = %multi.pos %multi.pos.win
    writeini $scriptdir $+ multidata.ini pos win %multi.pos 
    var %multi.pos.win.coord = $window($active).x $window($active).y $window($active).w $window($active).h
    writeini $scriptdir $+ multidata.ini windows  %multi.pos.win %multi.pos.win.coord 
    echo $colour(info) -a *** window %multi.pos.win added to the list
    if ($window(MultiserverDialog).state != $null) { multi.win.pos.setup }
  }
}

alias advertise { multi.me eliador }

;Multi.flood <QueryM NoticeM PingM InviteM CtcpM> < $+ .server>  
alias Multi.flood {
  var %MfloodType = $1
  if (%MfloodDetected. [ $+ [ %MfloodType ] ] == $null) {
    var %MtypeName = $gettok(%MfloodType,1,46)
    var %MfloodName = $left(%MtypeName,$calc($len(%MtypeName) - 1))
    inc %MfloodNumber. [ $+ [ %MfloodType ] ] 1
    if (%MfloodDetection. [ $+ [ %MfloodType ] ] == $null) { set %MfloodDetection. [ $+ [ %MfloodType ] ] [ on ] | .timerMFloodDetection. [ $+ [ %MfloodType ] ] 1  %MfloodInterval /MfloodDetectionCheck %MfloodType }
    if (%MfloodNumber. [ $+ [ %MfloodType ] ] >= %MfloodTrigger) {
      set %MfloodDetected. [ $+ [ %MfloodType ] ] [ on ]
      echo $colour(notice)  $active - $gettok(%MfloodType,2-,46) - %MfloodName flood detected : ignoring them during %MfloodTimer seconds
      .timerMFloodAlert. [ $+ [ %MfloodType ] ] 1 %MfloodTimer /stopMFloodAlert %MfloodType   
    }
  }
}

alias MfloodDetectionCheck {
  var %MfloodDetectionType = $1
  if (%MfloodNumber. [ $+ [ %MfloodDetectionType ] ] < %MfloodTrigger ) { set %MfloodNumber. [ $+ [ %MfloodDetectionType ] ] [ 0 ] }
  unset %MfloodDetection. [ $+ [ %MfloodDetectionType ] ]  
}

alias stopMFloodAlert {
  var %MfloodAlertType = $1
  var %MfloodAlertName = $left($gettok(%MfloodAlertType,1,46),$calc($len($gettok(%MfloodAlertType,1,46)) - 1))
  unset %MfloodDetection. [ $+ [ %MfloodAlertType ] ]
  set %MfloodNumber. [ $+ [ %MfloodAlertType ] ] [ 0 ]
  unset %MfloodDetected. [ $+ [ %MfloodAlertType ] ]
  echo $colour(notice)  $active - $gettok(%MfloodAlertType,2-,46) - Anti- $+ %MfloodAlertName flood measure off
}

Conclusion :


Voila ! :)

A voir également

Ajouter un commentaire Commentaires
Messages postés
7
Date d'inscription
lundi 26 décembre 2005
Statut
Membre
Dernière intervention
15 juillet 2008

bonjour antony je tombe sur se code bein sache que jhd peut se permetre de te dire que ecst nul va faire un jour un tour sur ses source et on nen reparlera moi je sais pas coder mais attention celle que jai pu avoir eds sienne dans mais main valent les tienne 100 fois ^^^^^^^^^^^^
Messages postés
17
Date d'inscription
samedi 26 mars 2005
Statut
Membre
Dernière intervention
27 août 2006

avant de metre ta source tu orait plus lexpliker :) meme si elle et pas de toi comme les otre dize :)
note:0 :O)
Messages postés
24
Date d'inscription
vendredi 13 août 2004
Statut
Membre
Dernière intervention
21 août 2007

moi je dis que reproduire un code a l'identique sa c'est ripper mais si tu le change un peu que personalise la chose alors la c pas pareil et puis infernalex a raison si on ne se fier qu'a 'aide mirc on serai encor qu'a l'auto-join mal scripter
c pas paske je suis noob que je dit sa mais paske c mon piont de vue
ps:anthony183 tu coner les droit d'auteur?
Messages postés
142
Date d'inscription
lundi 18 octobre 2004
Statut
Membre
Dernière intervention
8 juin 2006

euh juste ca serait bien si il y aurait au moins UN comentaire sur le code et pas sur anthony parce que :IL EST BIEN OU PAS ? (je suis un ripper moi (faut bien je rip j'essai de traduire c'est ma maniere d'apprendre(parce que l'aide mirc c'est un bordel la dedans)))

ps: pas ripper au point de posté des code pas de moi quand meme =X
Messages postés
2
Date d'inscription
jeudi 1 avril 2004
Statut
Membre
Dernière intervention
1 avril 2004

Je ne sais pas qui est Anthony mais en tout cas c'est un merdeux.
Quand on pompe un code, on cite la source.
La source en question c'est Eliador, du script MIRC Eliador (http://www.eliador.org).
Pomper les sources quand on est pas foutu de scripter ok .. mais tu pourrais au moins citer la source.
Afficher les 29 commentaires

Vous n'êtes pas encore membre ?

inscrivez-vous, c'est gratuit et ça prend moins d'une minute !

Les membres obtiennent plus de réponses que les utilisateurs anonymes.

Le fait d'être membre vous permet d'avoir un suivi détaillé de vos demandes et codes sources.

Le fait d'être membre vous permet d'avoir des options supplémentaires.