Add more IRC handlers
This commit is contained in:
parent
684a59f4f9
commit
621501eeed
1 changed files with 14 additions and 0 deletions
14
rowbot
14
rowbot
|
@ -410,6 +410,14 @@ on_JOIN() {
|
|||
info "%s has joined %s" "$from" "${args[0]}"
|
||||
}
|
||||
|
||||
on_KICK() {
|
||||
if (( ${#args[@]} == 3 )); then
|
||||
info "%s has kicked %s from %s: %s" "$from" "${args[1]}" "${args[0]}" "${args[@]:(-1)}"
|
||||
else
|
||||
info "%s has kicked %s from %s" "$from" "${args[1]}" "${args[0]}"
|
||||
fi
|
||||
}
|
||||
|
||||
on_MODE() {
|
||||
if (( ${#args[@]} == 2 )); then
|
||||
info "%s sets mode(s) %s on %s" "$from" "${args[1]}" "${args[0]}"
|
||||
|
@ -592,6 +600,12 @@ on_433() {
|
|||
fi
|
||||
}
|
||||
|
||||
on_438() {
|
||||
# The result will always be a string, since its the last index of the array.
|
||||
# shellcheck disable=SC2145
|
||||
error "${args[1]} couldn't change their nick to ${args[2]}: ${args[@]:(-1)}"
|
||||
}
|
||||
|
||||
on_473() {
|
||||
error "%s: %s" "${args[1]}" "${args[2]}"
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue