mIRC Homepage
Posted By: Garou kick counter - 09/06/07 07:15 PM
Not sure why but its not working anymore??

Code:

dialog kickcnt  {
  title "Auto kicks Count"
  size 300 200 450 310
  text "Set Kick Count Replay", 1, 15 15 175 15
  box "", 2, 1 0 445 300
  button "&Close", 7,120 270 50 25,flat, cancel
  combo 8, 10 60 155 200
  button "Set",9, 215 60 55 23,flat
  text "",11, 210 130 200 20
  text "",12, 210 160 200 20
  button "ON",13, 20 270 50 25,flat
  button "OFF",14, 70 270 50 25,flat
  button "Unset",15, 215 190 50 25,flat
  text " Kicks Unset set to 0",16, 210 130 200 20,hide
  check "",500, 200 250 200 30,push,flat,multi
}
on 1:dialog:kickcnt:sclick:*: { 
  if ($did == 9) { set %replay $did(8).text  }
  if ($did == 13) { .enable #Kickstatus ON | echo -a **12* Kick Count is On I will no auto Count You Kicks !  }
  if ($did == 14) { .disable #Kickstatus OFF |  echo -a **12* Kick Count is Off  auto Count Now Disable !  }
  if ($did == 15) { Unset %kicks | did -h kickcnt 11,12 | did -v kickcnt 16 }
  if ($did == 8) { did -a $dname 500 $did(8).text }
}

on 1:dialog:kickcnt:init:*:{
  did -o kickcnt 8 msg %replay
  did -a kickcnt 8 -( Kicklines )-
  did -a kickcnt 8 Kick Number
  did -a kickcnt 8 Kick #
  did -a kickcnt 8 Abuse Kick -
  did -a kickcnt 8 < Kick >
  did -a kickcnt 8 Victory Number
  did -a kickcnt 8 [Kicks] 
  did -a kickcnt 8 wk/b Number
  did -a kickcnt 8 Kick Count :
  did -a kickcnt 8 KickLines -
  did -a kickcnt 8 Ban Number
  did -a kickcnt 8 Lamer Num :
  did -a kickcnt 8 Kicks
  did -a kickcnt 8 [Kick Status]
  did -a kickcnt 8 « Kick »
  did -a kickcnt 8 Banned Lines
  did -a kickcnt 8 Abuse Number
  did -a kickcnt 8 Kickback
  did -a kickcnt 8 Victimization
  did -a kickcnt 8 -Kicklines-
  did -a kickcnt 8 -Kick Number-
  did -a kickcnt 8 -Kick-
  did -a kickcnt 8 -Ban Number-
  did -a kickcnt 8  Banned ! Kick
  did -a kickcnt 8  Kickstatus
  did -a kickcnt 11 Kick Count %kicks
  did -a kickcnt 12 Replay %replay %kicks
}

#Kickstatus on
alias kick { .inc %kicks 1 | kick $1- (  $+   %replay    %kicks   }
#Kickstatus END


Posted By: syr Re: kick counter - 09/06/07 07:31 PM
try this
Code:
 dialog kickcnt  {
  title "Auto kicks Count"
  size 300 200 450 310
  text "Set Kick Count Replay", 1, 15 15 175 15
  box "", 2, 1 0 445 300
  button "&Close", 7,120 270 50 25,flat, cancel
  combo 8, 10 60 155 200
  button "Set",9, 215 60 55 23,flat
  text "",11, 210 130 200 20
  text "",12, 210 160 200 20
  button "ON",13, 20 270 50 25,flat
  button "OFF",14, 70 270 50 25,flat
  button "Unset",15, 215 190 50 25,flat
  text " Kicks Unset set to 0",16, 210 130 200 20,hide
  check "",500, 200 250 200 30,push,flat,multi
}
on 1:dialog:kickcnt:sclick:*: { 
  if ($did == 9) { set %replay $did(8).text  }
  if ($did == 13) { .enable #Kickstatus ON | echo -a **12* Kick Count is On I will no auto Count You Kicks !  }
  if ($did == 14) { .disable #Kickstatus OFF |  echo -a **12* Kick Count is Off  auto Count Now Disable !  }
  if ($did == 15) { Unset %kicks | did -h kickcnt 11,12 | did -v kickcnt 16 }
  if ($did == 8) { did -a $dname 500 $did(8).text }
}

on 1:dialog:kickcnt:init:*:{
  did -o kickcnt 8 msg %replay
  did -a kickcnt 8 -( Kicklines )-
  did -a kickcnt 8 Kick Number
  did -a kickcnt 8 Kick #
  did -a kickcnt 8 Abuse Kick -
  did -a kickcnt 8 < Kick >
  did -a kickcnt 8 Victory Number
  did -a kickcnt 8 [Kicks] 
  did -a kickcnt 8 wk/b Number
  did -a kickcnt 8 Kick Count :
  did -a kickcnt 8 KickLines -
  did -a kickcnt 8 Ban Number
  did -a kickcnt 8 Lamer Num :
  did -a kickcnt 8 Kicks
  did -a kickcnt 8 [Kick Status]
  did -a kickcnt 8 « Kick »
  did -a kickcnt 8 Banned Lines
  did -a kickcnt 8 Abuse Number
  did -a kickcnt 8 Kickback
  did -a kickcnt 8 Victimization
  did -a kickcnt 8 -Kicklines-
  did -a kickcnt 8 -Kick Number-
  did -a kickcnt 8 -Kick-
  did -a kickcnt 8 -Ban Number-
  did -a kickcnt 8  Banned ! Kick
  did -a kickcnt 8  Kickstatus
  did -a kickcnt 11 Kick Count %kicks
  did -a kickcnt 12 Replay %replay %kicks
}

#Kickstatus on
alias kick { .inc %kicks 1 | kick # $1- (  $+   %replay    %kicks   }
#Kickstatus END 
Posted By: Garou Re: kick counter - 09/06/07 07:49 PM
Not working :P
Posted By: RusselB Re: kick counter - 09/06/07 10:22 PM
This line is missing a bracket
Code:
alias kick { .inc %kicks 1 | kick # $1- (  $+   %replay    %kicks   }

Also note that kick is an internal command, so to ensure that you don't call the alias from within the alias, it's best to use !/kick inside the kick alias for the actual kick.
Posted By: SladeKraven Re: kick counter - 09/06/07 10:26 PM
Or /!kick smile
Posted By: RusselB Re: kick counter - 09/06/07 10:32 PM
oops...fingers go ahead of my brain.. nice catch.
Posted By: Garou Re: kick counter - 09/06/07 10:51 PM
Not working..is this right ?

alias kick { .inc %kicks 1 | !kick # $1- ( $+ %replay %kicks }
Posted By: sparta Re: kick counter - 09/06/07 11:26 PM
are you shure %replay have a value ? and when i looked at your code, why so many spaces ? in ur last example you removed them. and why an alias for kick?

;This goes in to remote, ALT + R in your mirc..
on *:KICK:#: {
if ($knick == $me) { inc %kicks }
}
;ends here

then use your kick counter and message in your kick..

;This also goes in to your remote
menu nicklist {
Test Kick:{ kick # $1 %replay %kicks }
}
;ends here

i know it can be done with a nicer code, but im to tired tonight.. wink
Posted By: Garou Re: kick counter - 09/06/07 11:38 PM
I use this from the menubar to open the dialog:
/dialog -dmn Kickcnt Kickcnt

I can see this now when i kick but i dont see what number iit is.
paaaaaaa was kicked by cobra (< Kick >)
Posted By: SladeKraven Re: kick counter - 09/06/07 11:44 PM
* You were kicked from #Test by Andy (Get out. (Victory Number 3) seems to work fine for me. crazy
Posted By: RoCk Re: kick counter - 10/06/07 12:20 AM
Originally Posted By: RusselB
to ensure that you don't call the alias from within the alias


That's impossible...

from the help file

An alias cannot call itself recursively mainly because this seems to cause more problems for users than it solves.
Posted By: RusselB Re: kick counter - 10/06/07 01:51 AM
I thought I'd read that, but for some reason couldn't find it in the help file. Looks like I need to replace my help file.
© mIRC Discussion Forums