Ok here's a version that actually works..heh.

Code:
alias messages {
    if (%spam <= 1) || (!%spam) {
      .msg $1 %r
      inc %spam 2
      return
    }
    else {
      var %i = 1, %n = $hget(messages,0).data, %match = $1 %r
      while (%i <= %n) {
        if ($hget(messages,%i).data == %match) { return }
        inc %i
      }    
      hadd messages $ctime $1 %r
    }
  }
on *:CONNECT: {
  if (!$hget(messages)) { hmake messages }
  .timer.messages 0 1 messagequeue
}
alias messagequeue {
  if (%spam > 0) { dec %spam 1 }
  if ($hget(messages,0).item > 0) {
    .msg $hget(messages, 1).data
    hdel messages $hget(messages, 1).item
    inc %spam 2
  }
}

This is the message queue. It hangs out on its own in a remote somewhere.

Code:
on *:text:!version:#: {
if ($nick isop #) {
  set -u0 %r Current Version 0.12.14.14 V. $+ $version
  messages $chan 
  }
}

Your on text events just set the message they wanna spew out at %r then call the messages alias word $chan sent along side so that the timed event knows where to send the message later on.

I don't think there is any problems with this version. Probably is though, cause I made it smile.

Last edited by Belhifet; 16/12/14 07:27 PM.