From 9d776656386c3e794187810c466b18ba29575248 Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Wed, 19 Oct 2016 10:19:21 +1300 Subject: Add drakon(6df) --- .gitignore | 1 + Makefile | 4 +++- games/drakon.awk | 15 +++++++++++++++ man/man6/drakon.6df | 20 ++++++++++++++++++++ 4 files changed, 39 insertions(+), 1 deletion(-) create mode 100644 games/drakon.awk create mode 100644 man/man6/drakon.6df diff --git a/.gitignore b/.gitignore index 1e9e814f..96279895 100644 --- a/.gitignore +++ b/.gitignore @@ -11,6 +11,7 @@ bin/su2d bin/tot bin/unf games/acq +games/drakon games/kvlt games/rot13 games/zs diff --git a/Makefile b/Makefile index 0e21851e..252a83d6 100644 --- a/Makefile +++ b/Makefile @@ -96,6 +96,7 @@ clean distclean : bin/tot \ bin/unf \ games/acq \ + games/drakon \ games/kvlt \ games/rot13 \ games/zs \ @@ -210,7 +211,8 @@ install-finger : install -pm 0644 -- finger/project "$(HOME)"/.project install -pm 0644 -- finger/pgpkey "$(HOME)"/.pgpkey -install-games : games/acq games/kvlt games/rot13 games/zs check-games install-games-man +install-games : games/acq games/drakon games/kvlt games/rot13 games/zs \ + check-games install-games-man install -m 0755 -d -- "$(HOME)"/.local/games for name in games/* ; do \ [ -x "$$name" ] || continue ; \ diff --git a/games/drakon.awk b/games/drakon.awk new file mode 100644 index 00000000..5d73f74d --- /dev/null +++ b/games/drakon.awk @@ -0,0 +1,15 @@ +# TyPe lIkE AnDoR DrAkOn fRoM AnCiEnT DoMaInS Of mYsTeRy +# +{ + for (i = 1; i <= length($0); i++) { + c = substr($0, i, 1) + if (i % 2) { + c = tolower(c) + } + else { + c = toupper(c) + } + s = s c + } + print s +} diff --git a/man/man6/drakon.6df b/man/man6/drakon.6df new file mode 100644 index 00000000..81b2b540 --- /dev/null +++ b/man/man6/drakon.6df @@ -0,0 +1,20 @@ +.TH DRAKON 6df "October 2016" "Manual page for drakon" +.SH NAME +.B drakon +\- type like Andor Drakon from Ancient Domains of Mystery +.SH USAGE +$ +.B drakon +/usr/share/dict/words +.br +lynx -dump https://sanctum.geek.nz/ | +.B drakon +.SH DESCRIPTION +.B drakon +emulates a "studlycaps" filter for the text given on standard input that +resembles the format used for the speech of Andor Drakon, the Elder Chaos God, +from the highly recommended roguelike game Ancient Domains of Mystery. +.SH SEE ALSO + +.SH AUTHOR +Tom Ryder -- cgit v1.2.3