Just increase a value and make an if statement saying that if the value is high enough then message the channel.

Code:
on *:text:text:#: { 
  if (%c == 3) { msg # Please wait another $duration(%cooldown) $+ . | unset %c }
  elseif (%cooldown) inc %c
  else {
    set -z %cooldown 30
    set %c 1
    msg # blablabla 
  }
}