File: newaway

package info (click to toggle)
ircii 4.4-3
  • links: PTS
  • area: main
  • in suites: hamm, slink
  • size: 4,256 kB
  • ctags: 2,797
  • sloc: ansic: 36,743; sh: 907; makefile: 483; lex: 16
file content (38 lines) | stat: -rw-r--r-- 838 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
# the new `show away once' script,
# matthew green, oct 1993.  i hate you
# this script uses serial number 311
# $Id: newaway,v 1.1 1994/01/17 08:30:58 mrgreen stable $
# this script is public domain

# this interfere's, but it really doesn't matter.

^set show_away_once off
alias n.o
	if (SHOW_NUMERICS == [ON])
		{@function_return = [$0]}
		{@function_return = [***]}

alias newaway.show
{
	@junk.nick = encode($tolower($0))
	@junk.away = encode($tolower($1-))
	if (newaway.nick[$junk.nick] == junk.away)
	{
		@function_return = 0
	}
	{
		@function_return = 1
		@newaway.nick[$junk.nick] = junk.away
	}
	if (0 != newaway.whois)
	{
		@function_return = 1
	}
	^assign -junk.nick
	^assign -junk.away
}

on #-311 311 * @newaway.whois = 1
on #-318 311 * @newaway.whois = 0

on ^301 * if (newaway.show($*)) { echo $n.o($H) $0 is away: $1- }