mIRC Home    About    Download    Register    News    Help

Print Thread
Groups #204334 16/09/08 01:57 AM
Joined: Apr 2007
Posts: 228
M
Mpot Offline OP
Fjord artisan
OP Offline
Fjord artisan
M
Joined: Apr 2007
Posts: 228
So I've been out of the game for several months now, and I've gone and forgotten how to use groups and I can't seem to find the help file. I remember something like

#asdf on
code
#asdf end

But I'm not sure if that's correct. Furthermore, is there an identifier to indicate whether or not a group is turned on or off?

Thanks.

Re: Groups [Re: Mpot] #204336 16/09/08 02:14 AM
Joined: Dec 2002
Posts: 2,022
R
RoCk Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Dec 2002
Posts: 2,022

Your example is correct.

/enable #asdf
/disable #asdf
//echo -a $group(#asdf)

/help groups

Re: Groups [Re: Mpot] #204337 16/09/08 02:15 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
That is correct. As to the identifier, you're looking for $group(#group_name) or $group(N).status

You should be able to call up the help file from inside mIRC, using /help


Re: Groups [Re: RusselB] #204353 16/09/08 06:51 PM
Joined: Apr 2007
Posts: 228
M
Mpot Offline OP
Fjord artisan
OP Offline
Fjord artisan
M
Joined: Apr 2007
Posts: 228
Thanks for the refresher guys. That was exactly what I've needed and I found the help file as well.

Re: Groups [Re: Mpot] #208510 22/01/09 06:11 AM
Joined: Nov 2006
Posts: 143
X
xyzzy Offline
Vogon poet
Offline
Vogon poet
X
Joined: Nov 2006
Posts: 143
menu channel {
Protection
.On:./enable #prot
.Off:./disable #prot
}
i see 'Protection' in channel right click but want make it 'Protection Off' when #prot is already enabled so ill click it and disable #prot confused i just want to make it easy to turn on/off.

Re: Groups [Re: xyzzy] #208511 22/01/09 06:32 AM
Joined: Nov 2006
Posts: 1,559
H
Horstl Offline
Hoopy frood
Offline
Hoopy frood
H
Joined: Nov 2006
Posts: 1,559
Use $iif conditions to build a switch.
In addition, you could show the current group status per $group(Name).status, or indicate the current group status with $iif and $style, or change the menu text ("name the switch") according to the group status...
Three examples:

Code:
menu channel {
  Protection
  .Toggle Protection : $iif(($group(#prot).status == on),disable,enable) #prot
}

menu channel { 
  Protection $+([,$group(#prot).status,]) : $iif(($group(#prot).status == on),disable,enable) #prot
}

menu channel {
  $iif(($group(#prot).status == on),$style(1)) Protection 
  .$iif(($group(#prot).status == on),disable,enable) Protection : $iif($group(#prot).status == on,.disable,.enable) #prot
}

Re: Groups [Re: Horstl] #208512 22/01/09 07:27 AM
Joined: Nov 2006
Posts: 143
X
xyzzy Offline
Vogon poet
Offline
Vogon poet
X
Joined: Nov 2006
Posts: 143
Thankss Horstl i just work on it a bit and get what i needed from ur code this part what i were wanted cheers
menu channel {
.$iif(($group(#flood).status == on),disable,enable) Protection : $iif($group(#flood).status == on,.disable,.enable) #flood
}