Jump to content

Anti Owner And Multiple Scripts


nullpanther

Recommended Posts

I run a buzzen with with another set of people we run multiple scripts mainly hybrid flash and soulfly anywho we have had problems with out chatters issuing hammers without permission i have this snippet here to stop this

 

 

 

menu channel {
  Anti Status
  .Anti Owner ( $+ $group(#antiowner) $+ )
  .$iif($group(#antiowner) == on,$style(2),$style(0)) On: .enable #antiowner | echo -a 0,12Anti-Owner $+ 0,94On
  .$iif($group(#antiowner) == off,$style(2),$style(0)) Off: .disable #antiowner | echo -a 0,12Anti-Owner $+ 0,4Off
  .Anti Host ( $+ $group(#antihost) $+ )
  .$iif($group(#antihost) == on,$style(2),$style(0)) On: .enable #antihost | echo -a 0,12Anti-Host $+ 0,94On
  .$iif($group(#antihost) == off,$style(2),$style(0)) Off: .disable #antihost | echo -a 0,12Anti-Host $+ 0,4Off
}

#antiowner off
on *:OWNER:#:{
  if ($me isowner $chan) {
    if ($opnick == $me ) halt {
      if ($nick == $me) halt {
        else mode $chan -q $opnick 
        msg $chan Sorry $replace($nick,>,Guest_) $+ , only I set who becomes OWNER in this room
        access $chan delete OWNER $nick
        access $chan delete OWNER $address($nick,1)
      }
    }
  }
}
#antiowner end

#antihost off
on *:oP:#:{
  if ($me isop $chan) {  
    if ($opnick == $me ) halt {
      if ($nick == $me) halt {
        else mode $chan -o $opnick 
        msg $chan Sorry $replace($nick,>,Guest_) $+ , only I set who becomes HOST in this room.
        access $chan delete HOST $nick
        access $chan delete HOST $address($nick,1)
      }
    }
  }
}
#antihost end

 

 

But this has one downfall it will only allow my script to issue hammers and i need it to allow the other two scripts to issue hammers to the chatters along with mine as we all have different hosts lists. Any help?

 

*Edit by X-Fusion -- Code tags added.

Edited by X-Fusion
Link to comment
Share on other sites

With SoulFly you can use the allowed list. You will need to load the 'sfb_prot.ini' file.

 

 

Then begin your events with:

 

 

if ($hget(prot,$+(all.,$gettok($address,1,64)))) { return }

 

 

 

#antiowner off
on !.*:OWNER:#:{
  if ($opnick == $me ) || ($hget(prot,$+(all.,$gettok($address,1,64)))) { return }
  mode $chan -q $opnick | msg $chan Sorry $replace($nick,>,Guest_) $+ , only I set who becomes OWNER in this room
  access $chan delete OWNER $nick | access $chan delete OWNER $address($nick,1)
}
#antiowner end

 

 

Notice the changes I made?

Edited by Travis
Link to comment
Share on other sites

Mainly it wasn't working because you were halting commands, and it couldn't move on to the other commands. The coding was wrong, but try this...

 

menu channel {
  Anti Status
  .Anti Owner ( $+ $group(#antiowner) $+ )
  .$iif($group(#antiowner) == on,$style(2),$style(0)) On: .enable #antiowner | echo -a 0,12Anti-Owner $+ 0,94On
  .$iif($group(#antiowner) == off,$style(2),$style(0)) Off: .disable #antiowner | echo -a 0,12Anti-Owner $+ 0,4Off
  .Anti Host ( $+ $group(#antihost) $+ )
  .$iif($group(#antihost) == on,$style(2),$style(0)) On: .enable #antihost | echo -a 0,12Anti-Host $+ 0,94On
  .$iif($group(#antihost) == off,$style(2),$style(0)) Off: .disable #antihost | echo -a 0,12Anti-Host $+ 0,4Off
}

#antiowner off
on *:OWNER:#:{
  if ($me isowner $chan) {
    if ($opnick == $me ) halt
    elseif ($nick == $me) halt
    else {
      mode $chan -q $opnick
      msg $chan Sorry $replace($nick,>,Guest_) $+ , only I set who becomes OWNER in this room
      access $chan delete OWNER $nick
      access $chan delete OWNER $address($nick,1)
    }
  }
}
#antiowner end

#antihost off
on *:oP:#:{
  if ($me isop $chan) {  
    if ($opnick == $me ) halt
    elseif ($nick == $me) halt
    else {
      mode $chan -o $opnick
      msg $chan Sorry $replace($nick,>,Guest_) $+ , only I set who becomes HOST in this room.
      access $chan delete HOST $nick
      access $chan delete HOST $address($nick,1)
    }
  }
}
#antihost end

Link to comment
Share on other sites

I dont think he was having issues with the code, he just wanted to have an allowed list added. Yeah War, when people script like that it bugs me,. but mIRC seems to take it. It looks so bass ackwArds! But mIRC doesn't care... It's still the wrong way!! lol

 

 

Read up on if, elseif & else...

 

if (comparison) { commands }

 

 

^^^^^^^^^^^^^^^^^^^

 

That's correct syntax.

 

if ($me !isop $chan) { halt }

^this is right

 

 

if ($me !isop $chan) halt {

^this is wrong (I dont care what mIRC says) :P

 

 

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...