rawmode deown/dehost protection

By Tubz on Jul 27, 2012

Raw event with hash tables for mirc
Let me know what you think :)
copy and paste
no idea if its faster than on deop/on deowner

on *:RAWMODE:#:{
  hadd -m revuser $ial($nick).user $ial($nick).addr $nick
  hadd -m r k $r(1111111,9999999)
  if ($2 != $nick) && ($2 == $me) {
    if ($1 == -q) {
      mode $me +h $hget(data,# $+ q)
      access # clear owner $rgate 0
      mode # -q $rname
      prop # ownerkey $hget(r,k)

    elseif ($1 == -o) {
      mode $me +h $hget(data,# $+ o)
      access # clear host $rgate 0
      mode # -o $rname
      prop # ownerkey $hget(r,k)
  hfree revuser

alias rgate { return $gettok($hget(revuser,$ial($nick).user),1,32) }
alias rname { return $gettok($hget(revuser,$ial($nick).user),2,32) }


Sign in to comment.
Tubz   -  Jul 28, 2012

im on vibesn @ the moment .ocx
Must it be an on irc sniplet? O-O

_Dean_   -  Jul 27, 2012

you need to specify that the user needs owner access or OPER override +v to use

mode # -q $rname

some networks does not has "access" as alias in services, and the command "clear" will clear the entire list, not only a specific level

 access # clear owner $rgate 0

if someone uses

mode # -qaohv $str($nick,5)

they wont have any privileges to "deop" or "deowner" someone, to use "mode"

for what is this line made for?

mode $me +h $hget(data,# $+ q)

UMODE +h in some networks are only for Staff members or IRCops

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.