mIRC Home    About    Download    Register    News    Help

Print Thread
#205202 16/10/08 06:41 PM
Joined: Feb 2003
Posts: 3,432
S
sparta Offline OP
Hoopy frood
OP Offline
Hoopy frood
S
Joined: Feb 2003
Posts: 3,432
I want to edit the default alias for /quit, and i tested to use:
Code:
alias quit {
  if (!$1) { qquit no quit message }
  else { qquit $1- }
}
alias qquit { !quit $1- }

I also tested to just use:
Code:
alias quit {
  if (!$1) { .quit no quit message }
  else { .quit $1- }
}

But no luck, the thing i want to do is to ether send a default message if $1 == $null, or if $1 != $null send the message send by the users, how can i do this ?


if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
Joined: Mar 2007
Posts: 218
V
Fjord artisan
Offline
Fjord artisan
V
Joined: Mar 2007
Posts: 218

Code:
alias quit {
  if (!$1) { .quit no quit message }
  else { .quit $1- }
}


Your above code works perfectly, if you type /quit or /quit bye.


Code:
on ^*:Quit: {
  var %i = 1
  while $comchan($nick,%i) {
    echo -i18 $v1 -> $nick quit irc stating [ $+ $iif($1- = $null,no message given.,$1-) $+ ]
    inc %i
  }
  halt
}


And the above is what i used when other people quit.

Joined: Feb 2003
Posts: 3,432
S
sparta Offline OP
Hoopy frood
OP Offline
Hoopy frood
S
Joined: Feb 2003
Posts: 3,432
I have a alias for other people when they quit smile but my alias don't work for me, and i have no other alias for quit


if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
Joined: Nov 2006
Posts: 1,559
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Nov 2006
Posts: 1,559
Works for me too.
Maybe your connection time (for testing) is below a certain limit to display your messages. Unreal (for example) has a setting in the set block for this: "set::anti-spam-quit-message-time <timevalue>"

To verify, try e.g.:
Code:
alias quit {
  if (!$1) { echo -sn Quit: no msg | .quit no quit message }
  else { echo -sn Quit: custom msg: $1- | .quit $1- }
}



Link Copied to Clipboard