From f199aff05248164cc49391de2e9785416e9902fb Mon Sep 17 00:00:00 2001 From: "shackspace e.V" Date: Thu, 6 May 2010 22:47:01 +0200 Subject: prepared /join and /part for room based chatting --- modules/atwall | 11 ----------- modules/chat | 11 +++++++++++ modules/join | 10 ++++------ modules/part | 10 ++++++++++ 4 files changed, 25 insertions(+), 17 deletions(-) delete mode 100755 modules/atwall create mode 100755 modules/chat create mode 100755 modules/part (limited to 'modules') diff --git a/modules/atwall b/modules/atwall deleted file mode 100755 index 66fca5e6..00000000 --- a/modules/atwall +++ /dev/null @@ -1,11 +0,0 @@ -#! /bin/sh - -case "$1" in - (--help) echo send text to everyone with @@ prepended ;; - (q) - echo quit chat mode - echo /set default_command espeak >$NOISE_linefeed;; - - (*) - echo /wall @@ $* >$NOISE_linefeed -esac diff --git a/modules/chat b/modules/chat new file mode 100755 index 00000000..66fca5e6 --- /dev/null +++ b/modules/chat @@ -0,0 +1,11 @@ +#! /bin/sh + +case "$1" in + (--help) echo send text to everyone with @@ prepended ;; + (q) + echo quit chat mode + echo /set default_command espeak >$NOISE_linefeed;; + + (*) + echo /wall @@ $* >$NOISE_linefeed +esac diff --git a/modules/join b/modules/join index af1c0117..0e0bec2a 100755 --- a/modules/join +++ b/modules/join @@ -1,14 +1,12 @@ #! /bin/sh case "$1" in - (--help) echo set default_command to atwall and back ;; - (off) - echo /set default_command espeak >$NOISE_linefeed - echo "disabled chat mode (set back to espeak)" ;; + (--help) echo set default_command to chat and join channel ;; (*) echo /set default_command atwall >$NOISE_linefeed - echo "enabled chat mode" - echo q or /chat off to go back to espeak ;; + echo /set chat_channel $1 >$NOISE_linefeed + echo "joined channel $1" + echo /part off to go back to espeak ;; esac diff --git a/modules/part b/modules/part new file mode 100755 index 00000000..beb95163 --- /dev/null +++ b/modules/part @@ -0,0 +1,10 @@ +#! /bin/sh + +case "$1" in + (--help) echo leave chat mode ;; + (*) + echo /set default_command espeak >$NOISE_linefeed + echo "disabled chat mode (set back to espeak)" ;; + + +esac -- cgit v1.2.3