Alternative to DaveC's method would be signals.

Code:
on *:TEXT:!*:#mirc: { .signal command $chan $nick $1- }
on *:INPUT:#mirc: { if (!* iswm $1-) .signal command $active $me $1- }

on *:SIGNAL:command:{
  var %source = $1, %target = $2
  /tokenize 32 $3-

  if ($1 == !update) { ... }
}