When a script triggers an "on PART" event and ($nick == $me)... mIRC does not erase the channel's information from memory until
after the script finishes.
$chan($chan) isnum
$nick($chan, 0) isnum
With an "on KICK" when ($knick == $me)... the channel info is lost
before the event triggers.
$chan($chan) == $null
$nick($chan, 0) == $null
For consistensy, these 2 should work in the same fashion. I would rather see the info lost AFTER (as in the on PART), since this information can be vital to scripts.