mIRC Home    About    Download    Register    News    Help

Print Thread
kick counter #178386 09/06/07 07:15 PM
Joined: Aug 2006
Posts: 469
G
Garou Offline OP
Fjord artisan
OP Offline
Fjord artisan
G
Joined: Aug 2006
Posts: 469
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



Re: kick counter [Re: Garou] #178387 09/06/07 07:31 PM
Joined: Oct 2006
Posts: 15
S
syr Offline
Pikka bird
Offline
Pikka bird
S
Joined: Oct 2006
Posts: 15
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 

Re: kick counter [Re: syr] #178390 09/06/07 07:49 PM
Joined: Aug 2006
Posts: 469
G
Garou Offline OP
Fjord artisan
OP Offline
Fjord artisan
G
Joined: Aug 2006
Posts: 469
Not working :P

Re: kick counter [Re: Garou] #178393 09/06/07 10:22 PM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
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.

Re: kick counter [Re: RusselB] #178394 09/06/07 10:26 PM
Joined: Dec 2002
Posts: 3,547
S
SladeKraven Offline
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Or /!kick smile

Re: kick counter [Re: SladeKraven] #178395 09/06/07 10:32 PM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
oops...fingers go ahead of my brain.. nice catch.

Re: kick counter [Re: RusselB] #178396 09/06/07 10:51 PM
Joined: Aug 2006
Posts: 469
G
Garou Offline OP
Fjord artisan
OP Offline
Fjord artisan
G
Joined: Aug 2006
Posts: 469
Not working..is this right ?

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

Re: kick counter [Re: Garou] #178398 09/06/07 11:26 PM
Joined: Feb 2003
Posts: 3,432
S
sparta Offline
Hoopy frood
Offline
Hoopy frood
S
Joined: Feb 2003
Posts: 3,432
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

Last edited by sparta; 09/06/07 11:27 PM.

if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
Re: kick counter [Re: sparta] #178399 09/06/07 11:38 PM
Joined: Aug 2006
Posts: 469
G
Garou Offline OP
Fjord artisan
OP Offline
Fjord artisan
G
Joined: Aug 2006
Posts: 469
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 >)

Re: kick counter [Re: Garou] #178400 09/06/07 11:44 PM
Joined: Dec 2002
Posts: 3,547
S
SladeKraven Offline
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
* You were kicked from #Test by Andy (Get out. (Victory Number 3) seems to work fine for me. crazy

Re: kick counter [Re: RusselB] #178404 10/06/07 12:20 AM
Joined: Dec 2002
Posts: 2,010
R
RoCk Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Dec 2002
Posts: 2,010
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.

Re: kick counter [Re: RoCk] #178409 10/06/07 01:51 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
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.