Common Channels

By F*U*R*B*Y* on Apr 16, 2007

Just a simple common channel thingy, it gets all the channel that you and the person that has just joint, and it says it in the channel on which they joined

on *:JOIN:#: {
  if ($nick == $me) { halt }
  else {
    unset %lol
    var %total = $comchan($nick,0), %x = 1
    while ( %x <= %total ) {
      set %lol %lol $+ , $+ $comchan($nick,%x)
      inc %x
    msg # $nick is in the following channels that i am in: $replace(%lol,$chr(44),$chr(32))


Sign in to comment.
extremity   -  Jun 24, 2012


on !*:JOIN:#:{

to remove

if ($nick == $me) { halt }

As posted by DarthRaven and xDaeMoN .. .. Maybe some type of character confusion..

Regardless.. nice little snippet

Jethro   -  Jun 24, 2012

[85], what's up with that? The ^ prefix is usually used to halt default text event or to have an event prioritized before other events.

[85]   -  Jun 24, 2012
 on ^*:JOIN:#:{  
DarthReven   -  Apr 16, 2007

Try using $addtok to add your tokens with the ASCII Character you want between the respective tokens. EX:

on !*:join:#: {
  if ($comchan($nick,0) > 1) {
    var %output, %start 1
    while ($comchan($nick,1)) { %output = $addtok(%output,$v1,32) | inc %start }
    msg $chan %output
xDaeMoN   -  Apr 16, 2007

The last part of my post will remove line below

 if ($nick == $me) { halt }
xDaeMoN   -  Apr 16, 2007

Declare %lol as a local var so no need to unset them, so include \"%lol\" in the \"var ....\" line

Change this line

set %lol %lol $+ , $+ $comchan($nick,%x)


%lol = %lol $comchan($nick,%x)

so there is no need to use $replace as the channels are already being added in the variable separated by a space.

Use \"!\" in your ON Join event which means \"except you\"

on !*:JOIN:#: {


Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.