mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: May 2005
Posts: 25
E
Er1C Offline OP
Ameglian cow
OP Offline
Ameglian cow
E
Joined: May 2005
Posts: 25
Hi!

I'm looking for a little script. This is the situation.

Two channels on the same server.
If a user is in #1, he get's voice in #2. When he leaves #1, his voice will be removed in #2. That's all.

Is this possible? Maybe there is already a script made for this?

I searched first and tried but cannot find what we are looking for.

Thanks in advance.

Joined: Aug 2005
Posts: 525
S
Fjord artisan
Offline
Fjord artisan
S
Joined: Aug 2005
Posts: 525
Code:
on 1:join:#Channel2:{
  if ( $nick ison #Channel1 && $me isop #Channel2 ) { mode #Channel2 +v $nick }
}

on 1:part:#Channel1:{
  if ( $nick ison #Channel2 && $nick isvoice #Channel2 && $me isop #Channel2 ) { mode #Channel2 -v $nick }
}

Last edited by schaefer31; 22/09/05 07:17 PM.
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
Code:
on *:join:*: {
  if ($me !isop [color:red]#chan2[/color]) { return }
  if ($chan == [color:red]#chan1[/color]) {
    if ($nick ison [color:red]#chan2[/color] && $nick isreg [color:red]#chan2[/color]) {
      mode [color:red]#chan2[/color] +v $nick
    }
  }
  elseif ($chan == [color:red]#chan2[/color]) {
    if ($nick ison [color:red]#chan1[/color] && $nick isreg $chan) {
      mode $chan +v $nick
    }
  }
}
on *:part:[color:red]#chan1[/color]: {
  if ($me !isop [color:red]#chan2[/color]) { return }
  if ($nick ison [color:red]#chan2[/color] && $nick isvoice [color:red]#chan2[/color]) {
    mode [color:red]#chan2[/color] -v $nick
  }
}


This requires you to be in both channels. You'll also need to be opped in order to voice/devoice the person.

Replace #chan1 with the channel you want people to be in.
Replace #chan2 with the channel the person will get voiced/devoiced in.

Any questions, just ask.

EDIT: Well, I was beat. laugh

Anyhow, this is the same basic script as above, except it checks if you're opped, it won't bother voicing someone who's an op or already voiced, and it will voice the person regardless which channel is joined first.

Last edited by Riamus2; 22/09/05 07:19 PM.

Invision Support
#Invision on irc.irchighway.net
Joined: May 2005
Posts: 25
E
Er1C Offline OP
Ameglian cow
OP Offline
Ameglian cow
E
Joined: May 2005
Posts: 25
works smoothly !


Link Copied to Clipboard