|
brad2
|
brad2
|
ok, i just got my joins customized:
on ^*:JOIN:#:{
if ($nick != $me) {
//echo # 14[14 $+ $time(hh:nntt) $+ 14] 7* 9Joins: $nick 14( $+ $address $+ ) 7«14 $nick($chan,0) total users ( $+ $nick($chan,0,o) ops, $nick($chan,0,v,o) voices, $calc($nick($chan,0) - ($nick($chan,0,o) + $nick($chan,0,v,o))) others) 7»
haltdef
}
}
How can i make it when I join a channel, it echos to me the number of users? Now, i am trying to make the quits and parts customized too. the problem is, i can't get the quit message to show up. I just get something like.. * Quits: Nick (address) it wont show the quit message.. How do I do this?
Last edited by brad2; 01/07/03 02:39 AM.
|
|
|
|
Joined: Dec 2002
Posts: 3,534
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 3,534 |
Like this? sorry if I misread. I am quite tired. 
on ^*:quit: {
%quit.chan = $comchan($nick,1)
set %qtemp 0
:quit
inc %qtemp 1
if ($comchan($nick,%qtemp)) {
echo 2 $comchan($nick,%qtemp) $ntime *** $nick has quit IRC ( $+ $1- $+ )
goto quit
}
echo 2 -t $nick ( $+ $address $+ ) has quit IRC ( $+ $1- $+ )
unset %qtemp
haltdef
}
|
|
|
|
brad2
|
brad2
|
Yep, thats it.  Thanks... Now, how can i make it display to me the number of users when i join a channel
|
|
|
|
Joined: May 2003
Posts: 215
Fjord artisan
|
Fjord artisan
Joined: May 2003
Posts: 215 |
Damn you do things the hard way....
on ^*:QUIT: {
var %i = 1
while ($comchan($nick,%i) {
echo $color(quit) -t $ifmatch * Quit: $nick ( $+ $address $+ ) ( $+ $1- $+ )
inc %i
}
haltdef
}
For returning the number of users on a channel use $nick($chan,0)Here's some code I use...
on me:^*:join:#: {
echo $color(join) -t * Now talking in: $chan
.enable #join
halt
}
#join off
raw 353:*: {
echo $3 Users: @ - $nick($3,0,o) / % - $nick($3,0,h) / + - $nick($3,0,v) / regular - $nick($3,0,r) / total - $nick($3,0)
halt
}
raw 366:*: { .disable #join | halt }
#join end
Last edited by lammkott; 01/07/03 03:09 AM.
|
|
|
|
brad2
|
brad2
|
* /while: invalid format
????
|
|
|
|
Joined: Dec 2002
Posts: 3,015
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 3,015 |
He just missed a ), while ($comchan($nick,%i)) {
|
|
|
|
Joined: Dec 2002
Posts: 3,534
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 3,534 |
alias users {
set %users 1
:next
set %user $nick(#,%users)
if (%user == $null) { goto done }
if (%user ison #) { echo -t $chan %user is on $chan $+ . }
inc %users
goto next
:done
}
on *:JOIN:#: {
if ($nick == $me) { users }
}
I did read the post wrong. I thought you said list all the users on a channel. Oops. 
Last edited by SladeKraven; 01/07/03 03:15 AM.
|
|
|
|
Joined: Dec 2002
Posts: 1,518
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 1,518 |
on ^*:quit:{
if ($1-) var %reason = ( $+ $1- $+ )
var %i = 1
while ($comchan($nick,%i)) {
set -u10 %countnickz $calc($nick($comchan($nick,%i),0,a) - 1)
echo $color(quit) -ti2 $ifmatch *** D3m0nicChaos Quits:8 $nick 12( $+ $address $+ ) %reason 15 $calc($nick($comchan($nick,%i),0,a) - 1) $iif((%countnickz == 1),4Chatter,4Chatters)
inc %i
}
halt
}
thats what i used to make it count in my script ....... maybe its alil different than yours but i like mine as it takes in account saying your possibly the only one in the channel and changes the following from plural to singular ...... but then again thats just my taste in things also this can be modified to work with joins parts and kicks and every other event u wanna remodify ...... it then gives a count of users at the traling end of each one ..... nice neat and clean
|
|
|
|
brad2
|
brad2
|
Why won't this work for parts?
on ^*:PART: {
var %i = 1
while ($comchan($nick,%i)) {
echo $color(quit) -t $ifmatch 14[14 $+ $time(hh:nntt) $+ 14] 7* 4Parts:15 $nick 14( $+ $address $+ ) 7(14 $+ $1- $+ 7)
inc %i
}
haltdef
}
|
|
|
|
ScatMan
|
ScatMan
|
u forgot the TARGET part: on ^*:part:#: and u don't need a loop cuz u need to echo only in on channel
|
|
|
|
Joined: Dec 2002
Posts: 3,534
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 3,534 |
on ^*:PART:#: {
if ($1- == $null) { echo $color(quit) $chan 14[14 $+ $time(hh:nntt) $+ 14] 7* 4Parts:15 $nick 14( $+ $address $+ ) 7(14 $+ No message given. $+ 7) }
else { echo $color(quit) $chan 14[14 $+ $time(hh:nntt) $+ 14] 7* 4Parts:15 $nick 14( $+ $address $+ ) 7(14 $+ $1- $+ 7) }
haltdef
}
[07:18pm] * Parts: SladeKraven (DarkOne@=gvwfj.infinite-darkness.co.uk) (No message given) [07:18pm] * Parts: SladeKraven (DarkOne@=gvwfj.infinite-darkness.co.uk) (...)
|
|
|
|
brad2
|
brad2
|
Ok thanks for all the help on the quit/part messages. Now... how do i make it echo to me the number of users when I join a channel.
on me:^*:join:#: {
echo $color(join) -t * Now talking in: $chan
.enable #join
halt
}
#join off
raw 353:*: {
echo $3 Users:
@ - $nick($3,0,o) / % - $nick($3,0,h) / + - $nick($3,0,v) / regular - $nick($3,0,r) / total - $nick($3,0)
halt
}
raw 366:*: {
.disable #join | halt }
#join end
This doesnt do anything for me. any ideas? Also..
$nick($chan,0) total users ( $+ $nick($chan,0,o) ops, $nick($chan,0,v,o) voices, $calc($nick($chan,0) - ($nick($chan,0,o) + $nick($chan,0,v,o))) others)
i added that to the quit message. all it returns is " total users ( ops, voices, 0 others) " ??????
Last edited by brad2; 01/07/03 11:43 PM.
|
|
|
|
Joined: May 2003
Posts: 215
Fjord artisan
|
Fjord artisan
Joined: May 2003
Posts: 215 |
I made a small mistake in the join event, I've left out the $chan in the echo command, it should read
echo $color(join) -t $chan * Now talking in: $chan
If you're still having problems with it message me.
|
|
|
|
brad2
|
brad2
|
still doesnt work..i messaged you
|
|
|
|
|