Add exclamatio module support into annna-message-common. - annna - Annna the ni… | |
git clone git://bitreich.org/annna/ git://enlrupgkhuxnvlhsf6lc3fziv5h2hhfrinws6… | |
Log | |
Files | |
Refs | |
Tags | |
README | |
--- | |
commit e6f32ec12007683294f6bca1721847ac94b1f5a3 | |
parent c0655da913f533290a7600cc2c10507b9915e181 | |
Author: Annna Robert-Houdin <[email protected]> | |
Date: Sat, 7 Jan 2023 22:12:34 +0100 | |
Add exclamatio module support into annna-message-common. | |
Diffstat: | |
M annna-message-common | 9 ++++++++- | |
M exclamatio | 1 - | |
2 files changed, 8 insertions(+), 2 deletions(-) | |
--- | |
diff --git a/annna-message-common b/annna-message-common | |
@@ -221,7 +221,14 @@ esac | |
case "${text}" in | |
"${ircuser}"?) | |
exclamation="$(printf "${text}\n" | sed "s,${ircuser}\(.\),\1,g")" | |
- annna-say -s "${server}" -c "${channel}" "${user}${exclamation}" | |
+ exclamationsintime=$(exclamatio "${user}") | |
+ finalexclamation="${exclamation}" | |
+ while [ $exclamationsintime -gt 1 ]; | |
+ do | |
+ finalexclamation="${finalexclamation}${exclamation}" | |
+ exclamationsintime=$(($exclamationsintime - 1)) | |
+ done | |
+ annna-say -s "${server}" -c "${channel}" "${user}${finalexclamation}" | |
;; | |
*"<3"*) | |
annna-say -s "${server}" -c "${channel}" "*o.o*" | |
diff --git a/exclamatio b/exclamatio | |
@@ -40,7 +40,6 @@ function modifyexclamatio { | |
exclamatioval=$(getexclamatioval "${exclamatiotag}") | |
newexclamatioval="$(printf "%d%s\n" "${exclamatioval}" "$2" | bc)" | |
setexclamatioval "${exclamatiotag}" $newexclamatioval | |
- printf "%s = %d\n" "$exclamatiotag" "$newexclamatioval" | |
} | |
function incexclamatio { |