mIRC Homepage
Posted By: pilsken Mass op script? - 07/03/08 10:39 PM
Hey lads!

Im wondering if there is a simple mass op script out there?
Something like,

Php Code:
on owner:TEXT:*:#:{
if ($1 == ?op) && ($2 == *) { commands goes here... (need help) }
} 


Can someone please tell me how to do? Thx.
Posted By: SladeKraven Re: Mass op script? - 07/03/08 11:31 PM
Code:
on owner:TEXT:*:#:{
  if ($1 == ?op) && ($2 == *) {
    if ($me !isop #) echo -ac info * You're not opped on $+(#,.)
    else {
      var %i = 1,%m
      while ($nick(#,%i)) {
        var %n = $v1
        if ((!$istok($1-,%n,32)) && (%n !isop #)) {
          var %m = %m %n
          if ($numtok(%m,32) == $modespl) {
            .timer 1 0 mode # $+(+,$str(o,$v1)) %m
            var %m
          }
        }
        inc %i
      }
      if (%m) mode # $+(+,$str(o,$numtok($v1,32))) %m
    }
  }
}
Posted By: pilsken Re: Mass op script? - 08/03/08 03:08 AM
That doesn't work. frown

Well i want to use the "*" as a wildcard for op everyone who has not got op. Someone?

Best regards.
Posted By: sparta Re: Mass op script? - 08/03/08 10:57 AM
We don't help with mass scripts, simplue due they can be used to abuse other users and channels.. so i don't think you will get much help here
Posted By: RoCk Re: Mass op script? - 08/03/08 02:20 PM

Originally Posted By: sparta

We don't help with mass scripts...


Says who?
Posted By: Mpot Re: Mass op script? - 08/03/08 05:47 PM
Code:
on owner:TEXT:*:#:{
  if ($1 == ?op) && ($2 == *) {
    if ($me !isop #) echo -ac info * You're not opped on $+(#,.)
    else {
      var %i = 1,%m
      while ($nick(#,%i)) {
        var %n = $v1
        if ((!$istok($1-,%n,32)) && (%n !isop #)) {
          var %m = %m %n
          if ($numtok(%m,32) == $modespl) {
            .timer 1 0 mode # $+(+,$str(o,$v1)) %m
            var %m
          }
        }
        inc %i
      }
      if (%m) mode # $+(+,$str(o,$numtok($v1,32))) %m
    }
  }
}


That is really complicated looking. ._.
Posted By: pilsken Re: Mass op script? - 09/03/08 03:03 AM
Well, don't go offtopic please. Anyone have a better solution? Thx.
Posted By: Trashlord_ Re: Mass op script? - 09/03/08 03:44 AM
So you're looking to op people by matching address.

Code:
on @*:TEXT:?op*:#:{
var %i = 1
while ($nick($chan,%i)) {
var %nick = $v1
;loopon2-
var %2 = $numtok($2-,32)
while ($gettok($2-,%2,32)) {
if ($address(%nick,5) iswm $v1) { var %op = %op %nick }
dec %2
}
inc %i
}
;now, op them.
var %x = 0, %l = $numtok(%op,32), %do
while (%x < %l) {
inc %x
var %do = $addtok(%do,$gettok(%op,%x,32),32)
if ($numtok(%do,32) == $modespl) { mode $chan $str(o,$numtok(%do,32)) %do | var %do = $null }
}
if (%do) { mode $chan $str(o,$numtok(%do,32)) %do }
}


Note that I no longer use mIRC, and therefore this code remains untested.
© mIRC Discussion Forums