mIRC Home    About    Download    Register    News    Help

Print Thread
mIRC script #247961 11/09/14 03:11 AM
Joined: Sep 2014
Posts: 7
T
TitaniumG Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
T
Joined: Sep 2014
Posts: 7
Hi, I have a point system on my stream and was wondering if anyone has a script that will work with finding out who in the chat or overall on stream has the most points such as a top 5 or top 10 command such as !top 5, so it will list up the users and the amount they have? As i Have been asked this a few times and I cant find it anywhere. I know its possible as I have seen other streamers have it. If anyone can help me with the script it would be much appreciated.

Re: mIRC script [Re: TitaniumG] #247965 11/09/14 06:53 PM
Joined: Apr 2014
Posts: 170
Bramzee Offline
Vogon poet
Offline
Vogon poet
Joined: Apr 2014
Posts: 170
Code:
on *:TEXT:!top10:#:{
  if  ($nick isop #) { top10 # } 
  else { msg # You are not allowed to use !top10. }
}

alias -l top10 {
  window -h @. | var %i 1
  while $gettok($remove($read(points.ini,w,$+(*,$1,*),%i),[,]),2,46) {
    var %n $v1, %p $gettok($read(points.ini,$calc($readn + 1)),2,61)
    aline @. %n %p
    var %i $calc($readn + 1)
  }
  filter -cetuww 2 32 @. @.
  var %i 1 | while %i <= 10 {
    var %list $addtok(%list,$line(@.,%i),44)
    inc %i
  }
  msg $1 Top 10 point are: $replace(%list,$chr(44),$+($chr(44),$chr(32)))
  window -c @.
}

Re: mIRC script [Re: Bramzee] #247975 12/09/14 02:39 AM
Joined: Sep 2014
Posts: 7
T
TitaniumG Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
T
Joined: Sep 2014
Posts: 7
Thanks very much works as I wanted smile Do you know of a way to bring up how long the user has followed for?

Re: mIRC script [Re: TitaniumG] #247996 13/09/14 01:54 PM
Joined: Apr 2014
Posts: 170
Bramzee Offline
Vogon poet
Offline
Vogon poet
Joined: Apr 2014
Posts: 170
You'd have to make a script (or try finding one) that writes the new followers to a file and keeps track of it. But I'm not sure how that would work.

Re: mIRC script [Re: Bramzee] #248575 11/10/14 08:39 PM
Joined: Mar 2014
Posts: 52
P
patrickplays Offline
Babel fish
Offline
Babel fish
P
Joined: Mar 2014
Posts: 52
Originally Posted By: Bramzee
Code:
on *:TEXT:!top10:#:{
  if  ($nick isop #) { top10 # } 
  else { msg # You are not allowed to use !top10. }
}

alias -l top10 {
  window -h @. | var %i 1
  while $gettok($remove($read(points.ini,w,$+(*,$1,*),%i),[,]),2,46) {
    var %n $v1, %p $gettok($read(points.ini,$calc($readn + 1)),2,61)
    aline @. %n %p
    var %i $calc($readn + 1)
  }
  filter -cetuww 2 32 @. @.
  var %i 1 | while %i <= 10 {
    var %list $addtok(%list,$line(@.,%i),44)
    inc %i
  }
  msg $1 Top 10 point are: $replace(%list,$chr(44),$+($chr(44),$chr(32)))
  window -c @.
}


how would it work if i had a .ini that looks like that:
Code:
[#channel.nick1]
a=2

[#channel.nick2]
a=3
b=5


+ is there a more efficient way? because it takes about 1 minute for a 4085 lines .ini

Last edited by patrickplays; 11/10/14 09:17 PM.
Re: mIRC script [Re: patrickplays] #248646 14/10/14 07:40 PM
Joined: Mar 2014
Posts: 52
P
patrickplays Offline
Babel fish
Offline
Babel fish
P
Joined: Mar 2014
Posts: 52
cant get it to work >.<

GOT IT lol

Last edited by patrickplays; 14/10/14 07:50 PM.