mIRC Home    About    Download    Register    News    Help

Print Thread
#147935 26/04/06 09:50 PM
Joined: Nov 2005
Posts: 13
D
DJmart Offline OP
Pikka bird
OP Offline
Pikka bird
D
Joined: Nov 2005
Posts: 13
Can anyone please create a script that will VOICE users who are NOT voiced in channels I have access in?

I'm not sure how to go about doing this.

Thanks! shocked

#147936 26/04/06 10:03 PM
Joined: Dec 2004
Posts: 87
I
Babel fish
Offline
Babel fish
I
Joined: Dec 2004
Posts: 87
something like this ?

Code:
on *:join:* { if ($nick !== $me) { 
    mode # +v $nick
  }
}

  

#147937 26/04/06 10:25 PM
Joined: Nov 2005
Posts: 13
D
DJmart Offline OP
Pikka bird
OP Offline
Pikka bird
D
Joined: Nov 2005
Posts: 13
not really, more like a !voiceall

and that will trigger a voice to all users in the channels I specify

#147938 26/04/06 10:33 PM
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Code:
alias voiceall {
  var %x = 1
  while (%x <= $nick($1,0)) {
    if ($nick($1,%x) !isvo $1) mode $chan +v $nick($1,%x)
    inc %x
  }
}

On @*:Join:#: {
  voiceall $chan
}


*When someone joins the channel all users who aren't voiced will be.
*Or type /voiceall <#Channel> to voice all who aren't.

-Andy

#147939 26/04/06 10:42 PM
Joined: Nov 2005
Posts: 13
D
DJmart Offline OP
Pikka bird
OP Offline
Pikka bird
D
Joined: Nov 2005
Posts: 13
which area does this script go?

#147940 26/04/06 10:48 PM
Joined: Apr 2005
Posts: 1,009
Hoopy frood
Offline
Hoopy frood
Joined: Apr 2005
Posts: 1,009
remotes (alt+r)


IceCapped
#147941 26/04/06 11:28 PM
Joined: Sep 2005
Posts: 2,881
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,881
Code:
On @*:Join:#: {
  mode $chan +v $nick
}


This would make more sense. There's no need to call /voiceall when you're only voicing one person.

#147942 26/04/06 11:39 PM
Joined: Nov 2005
Posts: 13
D
DJmart Offline OP
Pikka bird
OP Offline
Pikka bird
D
Joined: Nov 2005
Posts: 13
Quote:
Code:
alias voiceall {
  var %x = 1
  while (%x &lt;= $nick($1,0)) {
    if ($nick($1,%x) !isvo $1) mode $chan +v $nick($1,%x)
    inc %x
  }
}

On @*:Join:#: {
  voiceall $chan
}


*When someone joins the channel all users who aren't voiced will be.
*Or type /voiceall <#Channel> to voice all who aren't.

-Andy



It doesn't seem to work..... its in remotes

#147943 26/04/06 11:49 PM
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Sorry change that $chan to $1.

-Andy

#147944 26/04/06 11:53 PM
Joined: Nov 2005
Posts: 13
D
DJmart Offline OP
Pikka bird
OP Offline
Pikka bird
D
Joined: Nov 2005
Posts: 13
Quote:
Sorry change that $chan to $1.

-Andy



which $chan theres two laugh

#147945 26/04/06 11:54 PM
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
He doesn't want one person voiced. He wants them all voiced. It's so when someone joins the channel it gives everyone a voice that don't have one.

Saves them having to type /voiceall <#Channel> for every channel he's on. That'd probably be simpler if the channel activity is next to none.

DJ: I was about to edit that post, the $chan in the alias. smile

-Andy

#147946 26/04/06 11:56 PM
Joined: Sep 2005
Posts: 2,881
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,881
It's still calling unnecessary code each time somebody joins.

Code:
on *:op:#:{
  if ($opnick == $me) voiceall $chan
}
on @*:join:#: mode $chan +v $nick

#147947 26/04/06 11:59 PM
Joined: Nov 2005
Posts: 13
D
DJmart Offline OP
Pikka bird
OP Offline
Pikka bird
D
Joined: Nov 2005
Posts: 13
Quote:
He doesn't want one person voiced. He wants them all voiced. It's so when someone joins the channel it gives everyone a voice that don't have one.

Saves them having to type /voiceall <#Channel> for every channel he's on. That'd probably be simpler if the channel activity is next to none.

DJ: I was about to edit that post, the $chan in the alias. smile

-Andy



I'm not sure its realling working.... heh i saved it in remotes, and changed what you said. i type /voiceall #slava

and it takes awhile before it does it......... any idea why the delay

#147948 27/04/06 03:34 AM
Joined: Apr 2006
Posts: 400
K
Fjord artisan
Offline
Fjord artisan
K
Joined: Apr 2006
Posts: 400
Code:
ON *:TEXT:*:*: {
  if ($1 !isop $chan) &amp;&amp; ($nick !isvo $chan) &amp;&amp; ($nick !ishop $chan) &amp;&amp; ($me isop $chan) {
    cs voice $chan $nick
  }
}



Can you not use this Sir DJmart? shocked


-Kurdish_Assass1n
#147949 27/04/06 06:41 AM
Joined: Aug 2005
Posts: 525
S
Fjord artisan
Offline
Fjord artisan
S
Joined: Aug 2005
Posts: 525
There's certainly no need to be checking $nick everytime something is said. I think the better method here would be to combine hixxy and SladeKraven's codes.

Code:
on @*:JOIN:[color:red]#YourChannel[/color]:{
  mode $chan +v $nick
}

alias voiceall {
  if ($me !isop $1) {
    echo -a Error: You are not opped on $1
  }
  else {
    var %i = 1, %l = $nick($1,0)
    while (%i &lt;= %l) {
      if ($nick($1,%i) !isvo $1) {
        mode $1 +v $nick($1,%i)
      }
      inc %i
    }
  }
}

menu nicklist {
  Voice All:voiceall
}


This voices all users on join.

It also puts an item in your nick list menu for voicing everyone. Simply click on it and it will voice any unvoiced nicks in the channel.

It makes more sense to do it this way then scan the entire nicklist everytime someone joins.

#147950 27/04/06 08:49 PM
Joined: Nov 2005
Posts: 13
D
DJmart Offline OP
Pikka bird
OP Offline
Pikka bird
D
Joined: Nov 2005
Posts: 13
Can we make that work for every channel? (that im in)

I am in multiple channels, that I have +o in. But I don't want it to be just one channel.

Nice script btw.

EDIT:
script constantly gives: "Error: You are not opped on"
on selection of Voice All

Last edited by DJmart; 27/04/06 09:02 PM.
#147951 27/04/06 11:16 PM
Joined: Aug 2005
Posts: 525
S
Fjord artisan
Offline
Fjord artisan
S
Joined: Aug 2005
Posts: 525
Sorry, I forgot to include the channel parameter with the nicklist item. You can make it work for other channels simply by adding them to the on join event. I've given an example in red.

Code:
on @*:JOIN:[color:red]#Channel1,#Channel2,#Channel3[/color]:{
  mode $chan +v $nick
}

alias voiceall {
  if ($me !isop $1) {
    echo -a Error: You are not opped on $1
  }
  else {
    var %i = 1, %l = $nick($1,0)
    while (%i &lt;= %l) {
      if ($nick($1,%i) !isvo $1) {
        mode $1 +v $v1
      }
      inc %i
    }
  }
}

menu nicklist {
  Voice All:voiceall $chan
}

#147952 27/04/06 11:18 PM
Joined: Aug 2005
Posts: 525
S
Fjord artisan
Offline
Fjord artisan
S
Joined: Aug 2005
Posts: 525
Or instead of listing channels like I showed, you can just replace the channel list with just #. It will then work for all channels that you are opped in. The @ prefix at the beginning will prevent it from executing if you are not opped in a given channel.

#147953 28/04/06 12:39 AM
Joined: Nov 2005
Posts: 13
D
DJmart Offline OP
Pikka bird
OP Offline
Pikka bird
D
Joined: Nov 2005
Posts: 13
WORKS GREAT!!!!

thank you ALL!


Link Copied to Clipboard