This will use your idle time on that channell instead of the network-wide $idle ($idle is reset after typing anything into any window at all).

on me:*:JOIN:#help:.timer $+ # 0 60 CheckIdle
alias CheckIdle {

  • if ($me !isop #help) && ($nick(#help,$me).idle >= 540) { part #help }
}
on me:*:part:#help:.timer $+ # off