This little snippet makes for a simple enable/disable section on your menu in which it will tell you weather the section is active, or not. It's useful in large bulky scripts with alot of menu items.
With that said, Enjoy.
menu status {
.Section ( $+ %sectionstatus $+ ) {
if ( %sectionstatus == off ) { //set %sectionstatus on | .enable #section }
elseif ( %sectionstatus == on ) { //set %sectionstatus off | .disable #section }
}
}
#section off
on *:TEXT:*hi*:#: { //msg $chan Hi $nick $+ ! }
;this is where the section to toggle goes.
#section end