mIRC Home    About    Download    Register    News    Help

Print Thread
check time and give points #125612 19/07/05 05:25 PM
Joined: Apr 2005
Posts: 72
B
bodo0815 Offline OP
Babel fish
OP Offline
Babel fish
B
Joined: Apr 2005
Posts: 72
hello
i have this:
Code:
on *:JOIN:#channel: {
    .timer 1 10 mk $nick #
  }
}
alias mk {
  if ($1 ison $2) { 
    hinc -m tmpj $1
    .timer 1 10 mk $1- 
  }
}

...this give on:join users one point every 10sec.
but i need another script that check the users in a channel
if i part or quit the channel

thx bodo

Re: check time and give points #125613 19/07/05 05:33 PM
Joined: Sep 2003
Posts: 4,230
D
DaveC Offline
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
You cant check if the users are in the channel if your not, well not without alot of whoising, and im blowed if im gonna write a server flooder!

Re: check time and give points #125614 19/07/05 05:58 PM
Joined: Apr 2005
Posts: 72
B
bodo0815 Offline OP
Babel fish
OP Offline
Babel fish
B
Joined: Apr 2005
Posts: 72
i will check if i join the room again :-)
and with a whoistimer?
how ever... how does look such a scipt?

thx bodo

Re: check time and give points #125615 19/07/05 11:10 PM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
To my knowledge you can't call an alias from within the alias, which is what you appear to be doing in the line
Code:
 alias mk {
  if ($1 ison $2) {
     hinc -m tmpj $1
  [color:red]    .timer 1 10 mk $1- [/color] 
   }
}
 


BTW: I'd be more than happy to be proven wrong on this point.

Re: check time and give points #125616 19/07/05 11:19 PM
Joined: Feb 2004
Posts: 2,019
FiberOPtics Offline
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2004
Posts: 2,019
He's not calling the alias from within the alias, he's putting it in a timer, which will call that alias 10 seconds later. There are more occasions where you can call the same command in the same alias, filter with -k flag comes to mind, or any custom alias that you script which overrides an internal command.

alias echo {
echo -a lol
}



Gone.