Probleme ON ^1:JOIN:#: {

Résolu
Soprano71 Messages postés 107 Date d'inscription vendredi 15 avril 2005 Statut Membre Dernière intervention 6 janvier 2009 - 3 août 2007 à 11:44
Soprano71 Messages postés 107 Date d'inscription vendredi 15 avril 2005 Statut Membre Dernière intervention 6 janvier 2009 - 3 août 2007 à 13:14
Bonjour tlm ! voila je souhaiterai savoir pk ce code ne fonctionne pas svp manque t'il quelque chose ?
code join :

ON ^1:JOIN:#: {
  If $nick != $me {
    If $gettok($read(configurations.txt,46),2,174) == Activé {      var %c 1, %n $lines(detect-channel.txt), %c2 = $chan
      while %c <= %n {
        If %c2 == $read(detect-channel.txt,%c) {          var %i 1, %t $lines(detect-pseudo.txt)
          while %i <= %t {
            var %txt = $read(detect-pseudo.txt,%i)
            If txt isin $nick {
              If $gettok($read(configurations.txt,54),2,32) == 1 { set %detect.averto $kick.phrase($read(menu\avertir\notice-pseudo.txt)) }
              ElseIf $gettok($read(configurations.txt,54),2,32) != 1 { set %detect.averto $kick.phrase($nick : $read(menu\avertir\notice-pseudo.txt)) }
              If $gettok($read(configurations.txt,51),2,32) == 3 {
                echo $chan �3; | echo $chan �3; $+ $colour(highlight text) $+ %signe.debut $+ �F;�3; $+ $colour(highlight text) $+ �1F;D�1F;étecteu�1F;r�1F; $+ %signe.fin �F;�3; $+ $colour(info2 text) $+ Pseudonyme �1F;[�1F;�3; $+ $colour(highlight text) $+ %txt $+ �3; $+ $colour(info2 text) $+ �1F;]�1F; | echo $chan $timestamp �3; $+ $colour(info2 text) Pseudo :�3; $+ $colour(highlight text) $nick | echo $chan �3; $+ $colour(highlight text) $+ %signe.debut $+ �F;�3; $+ $colour(highlight text) $+ �1F;D�1F;émarch�1F;e�1F; $+ %signe.fin �F;�3; $+ $colour(info2 text) $+ F10 : Avertir - F11 : Kick - F12 : Kickban | echo $chan �3;
              If $active != $chan { echo -a �3; | echo -a �3; $+ $colour(highlight text) $+ %signe.debut $+ �F;�3; $+ $colour(highlight text) $+ �1F;D�1F;étecteu�1F;r�1F; $+ %signe.fin �F;�3; $+ $colour(info2 text) $+ Pseudonyme �1F;[�1F;�3; $+ $colour(highlight text) $+ %txt $+ �3; $+ $colour(info2 text) $+ �1F;]�1F; | echo -a $timestamp �3; $+ $colour(info2 text) $+ Salon : $chan - Pseudo :�3; $+ $colour(highlight text) $nick | echo -a �3; $+ $colour(highlight text) $+ %signe.debut $+ �F;�3; $+ $colour(highlight text) $+ �1F;D�1F;émarch�1F;e�1F; $+ %signe.fin �F;�3; $+ $colour(info2 text) $+ F10 : Avertir - F11 : Kick - F12 : Kickban | echo -a �3; } | set %auto.qui $nick | set %channel.detect $chan | set %auto.raison $kick.phrase($read(menu\kicks\pseudo.txt)) | goto suite }
              ElseIf $gettok($read(configurations.txt,51),2,32) == 1 {
                If $gettok($read(configurations.txt,55),2,32) == 3 {
                  set %auto.qui $nick | set %channel.detect $chan | set %auto.raison $kick.phrase($read(menu\kicks\pseudo.txt))
                  If $me isop %channel.detect { .kick %channel.detect %auto.qui %auto.raison | unset %channel.detect | unset %auto.qui | unset %auto.raison | goto suite }
                  ElseIf ($me !isop %channel.detect) && (IriX ison %channel.detect) { .msg IriX kick %channel.detect %auto.qui %auto.raison | unset %channel.detect | unset %auto.qui | unset %auto.raison | goto suite }
                }
                ElseIf $gettok($read(configurations.txt,55),2,32) == 1 {
                  set %auto.qui $nick | set %channel.detect $chan | set %auto.raison $kick.phrase($read(menu\kicks\pseudo.txt))
                  If $me isop %channel.detect { .kick %channel.detect %auto.qui %auto.raison | unset %channel.detect | unset %auto.qui | unset %auto.raison | goto suite }
                }
                ElseIf $gettok($read(configurations.txt,55),2,32) == 2 {
                  set %auto.qui $nick | set %channel.detect $chan | set %auto.raison $kick.phrase($read(menu\kicks\pseudo.txt))
                  If $me isop %channel.detect { .kick %channel.detect %auto.qui %auto.raison | unset %channel.detect | unset %auto.qui | unset %auto.raison | goto suite }
                  ElseIf ($me isvoice %channel.detect) && (IriX ison %channel.detect) { .msg IriX kick %channel.detect %auto.qui %auto.raison | unset %channel.detect | unset %auto.qui | unset %auto.raison | goto suite }
                }
              }
              ElseIf $gettok($read(configurations.txt,51),2,32) == 2 {
                If $gettok($read(configurations.txt,55),2,32) == 3 {
                  set %auto.qui $nick | set %channel.detect $chan | set %auto.raison $kick.phrase($read(menu\kicks\pseudo.txt))
                  If $me isop %channel.detect { .ban %channel.detect %auto.qui 2 | .kick %channel.detect %auto.qui %auto.raison | unset %channel.detect | unset %auto.qui | unset %auto.raison | goto suite }
                  ElseIf ($me !isop %channel.detect) && (IriX ison %channel.detect) { .msg IriX ban # $address(%auto.qui,2) �1F;Detector.Syste�1F;m�1F; | .msg IriX kick %channel.detect %auto.qui %auto.raison | unset %channel.detect | unset %auto.qui | unset %auto.raison | goto suite }
                }
                ElseIf $gettok($read(configurations.txt,55),2,32) == 1 {
                  set %auto.qui $nick | set %channel.detect $chan | set %auto.raison $kick.phrase($read(menu\kicks\pseudo.txt))
                  If $me isop %channel.detect { .ban %channel.detect %auto.qui 2 | .kick %channel.detect %auto.qui %auto.raison | unset %channel.detect | unset %auto.qui | unset %auto.raison | goto suite }
                }
                ElseIf $gettok($read(configurations.txt,55),2,32) == 2 {
                  set %auto.qui $nick | set %channel.detect $chan | set %auto.raison $kick.phrase($read(menu\kicks\pseudo.txt))
                  If $me isop %channel.detect { .ban %channel.detect %auto.qui 2 | .kick %channel.detect %auto.qui %auto.raison | unset %channel.detect | unset %auto.qui | unset %auto.raison | goto suite }
                  ElseIf ($me isvoice %channel.detect) && (IriX ison %channel.detect) { .msg IriX ban # $address(%auto.qui,2) �1F;Detector.Syste�1F;m�1F; | .msg IriX kick %channel.detect %auto.qui %auto.raison | unset %channel.detect | unset %auto.qui | unset %auto.raison | goto suite }
                }
              }
            }

7 réponses

RCA ArKanis Messages postés 1287 Date d'inscription mercredi 21 avril 2004 Statut Membre Dernière intervention 21 février 2009
3 août 2007 à 11:50
pour débugger un code, il faut placer des echos un peu partout pour savoir par où il passe, avoir le contenu des variables, ...

on ne peut pas t'aider, on n'a pas ton fichier configurations.txt, ni pseudo.txt (quoi que celui là semblerait être un fichier qui contient des kicks ?), notice-pseudo.txt, detect-pseudo.txt, ...

au lieu des |, fais plutôt des retours à la ligne, c'est largement plus compréhensible, mieux lisible et mieux présenté de cette façon

Tu n'indiques pas non plus quelle partie ne fonctionne pas. Si tu veux qu'on t'aide plus efficacement, dis nous à peu près ce qui ne fonctionne pas (évite de dire tout :D)
3
Soprano71 Messages postés 107 Date d'inscription vendredi 15 avril 2005 Statut Membre Dernière intervention 6 janvier 2009
3 août 2007 à 11:54
ben le code ne kick pas le pseudo rentré ds  le pseudo text ou ne detecte pas
3
Soprano71 Messages postés 107 Date d'inscription vendredi 15 avril 2005 Statut Membre Dernière intervention 6 janvier 2009
3 août 2007 à 12:11
le configuration.txt indique si celui si et activé ou desactivé
le fichier pseudo.txt contient les pseudo rentré
3
RCA ArKanis Messages postés 1287 Date d'inscription mercredi 21 avril 2004 Statut Membre Dernière intervention 21 février 2009
3 août 2007 à 12:29
le plus simple aurait quand même été d'utiliser des fichiers .ini

je viens de voir une erreur par contre :
If txt isin $nick {

c'est plutôt if %txt isin $nick
3

Vous n’avez pas trouvé la réponse que vous recherchez ?

Posez votre question
Soprano71 Messages postés 107 Date d'inscription vendredi 15 avril 2005 Statut Membre Dernière intervention 6 janvier 2009
3 août 2007 à 13:02
merci ArKanis ! il y avai cet erreur et je vien de corigé :
If txt isin $nick { 
If %txt isin $strip($nick) { 
il manqué $strip(  ) tout fonctionne nikel  ! merci bcp  bonne journée  a tous  !
 
3
RCA ArKanis Messages postés 1287 Date d'inscription mercredi 21 avril 2004 Statut Membre Dernière intervention 21 février 2009
3 août 2007 à 13:09
il n'y a pas de codes couleur pourtant dans un nick oO
$strip($nick) devrait être inutile, vu que ça renverra toujours $nick
3
Soprano71 Messages postés 107 Date d'inscription vendredi 15 avril 2005 Statut Membre Dernière intervention 6 janvier 2009
3 août 2007 à 13:14
mdrr ben possible ! mais comme ça il detect bien le pseudo qui join le chan  et le kick kickban ou j'ai le choix ! faut avoué doit avoir un script assez special mdrrr !
3
Rejoignez-nous