alias vocop {
	if ([$0]==[ON] || [$0]==[OFF]) {
		@showop = [$0]
		xecho -b showing <$(hblk)@$(cl)nick> and <$(hblk)+$(cl)nick> in public set to $0 
		}{
			xecho -b modeshow value set to $showop
		}
}
	


on ^public * {
	if (ischanop($0 $1) && showop == [on]) {
		echo $fparse(format_public 1 $(hblk)@$(cl)$0 3 $2-)
		}
		if (!ischanop($0 $1) && !isvoice($1 $0) && showop != [off]) {
			echo $fparse(format_public 1 $0 3 $2-)
			}
			if (showop == [off]) {
                                echo $fparse(format_public 1 $0 3 $2-)
                        }      
			if (isvoice($1 $0) && showop == [on] && !ischanop($0 $1)) {
				echo $fparse(format_public 1 $(hblk)+$(cl)$0 3 $2-)		
				}
}

on ^public_other * {
	if (ischanop($0 $1) && showop == [on]) {
		echo $fparse(format_public_other 1 $(hblk)@$(cl)$0 $1 $2-)
		}
		if (!ischanop($0 $1) && !isvoice($1 $0) && showop != [off]) {
			echo $fparse(format_public_other 1 $0 $1 $2-)
			}
	
		if (showop == [off]) {
                                echo $fparse(format_public_other 1 $0 $1 $2-)
                        }      	
		if (isvoice($1 $0) && showop == [on] && !ischanop($0 $1)) {
				echo $fparse(format_public_other 1 $(hblk)+$(cl)$0 $1 $2-)		
				}
}

on ^send_public * {
	if (ischanop($N $0) && showop == [on]) {
		echo $fparse(format_send_public 1 2 $(hblk)@$(cl)$N $1-)
		}
		if (!ischanop($N $0) && !isvoice($0 $N) && showop != [off]) {
			echo $fparse(format_send_public 1 2 $N $1-)
			
			}
			if (showop == [off]) {
				echo $fparse(format_send_public 1 2 $N $1-)
			}
			if (isvoice($0 $N) && showop == [on]  && !ischanop($N $0)) {
				echo $fparse(format_send_public 1 2 $(hblk)+$(cl)$N $1-)		
				}
}
