if( !$check_only && is_registered($chan) &&
!cr_chk_flag($chan, (CRF_CLOSE | CRF_DRONE)) )
{
+ my $neverop = (is_neverop_user($user) || cr_chk_flag($chan, CRF_NEVEROP, 1));
+ my $no_deop = cr_chk_flag($chan, CRF_SPLITOPS, 0);
+ my $op_anyway = 0;
+ if($neverop && cr_chk_flag($chan, CRF_AUTOVOICE, 1) && $acc > 2) {
+ $acc = 2;
+ $no_deop = 0;
+ $op_anyway = 1;
+ }
set_modes($user, $chan, $acc,
# $acc == 3 is +h
# this probably needs to be configurable for ports
# also Unreal may [optionally] set +q on join.
- (($acc > 3) && cr_chk_flag($chan, CRF_SPLITOPS, 0)),
- !(is_neverop_user($user) || cr_chk_flag($chan, CRF_NEVEROP, 1)),
+ $no_deop,
+ !$neverop || $op_anyway,
);
}