Sorry, don't remember who made this one for me on ##mirc freenode, posting for archival purposes:

Code:
on ME:*:JOIN:#:{ set %awaycheck 1 | who $chan | .timer 0 3600 who $chan }
alias awaycheck {
  set %awaycheck 1
  var %azx = $active
  who $iif(!$1,%azx,$1)
}

raw 352:*:{
  if (%awaycheck) && ($chr(71) isin $7) { cline 14 $2 $6 }
  halt
}

raw 315:*:{ 
  if (%awaycheck) { unset %awaycheck } 
  halt 
}

Last edited by eahm; 12/06/18 08:00 AM.