Compare commits

..

4 Commits

Author SHA1 Message Date
b7f2ad6dcd
Implement Jeopardy cashout
This adds integration between Watbot and the Limnoria Jeopardy plugin.
If a game of Jeopardy ends, Watbot will parse the finishers message and
pay a small share of the Jeopardy price money in the form of Watcoins.
To avoid abuse, only Jeopardy finishing messages from authorized bots
are considered. An IRC user is considered an authorized bot if the
hostmask matches one of the configured bot hostmasks, and if the
nickname is configured for "jeopardy" in the newly introduced bot games
configuration.

Signed-off-by: Georg Pfuetzenreuter <mail@georg-pfuetzenreuter.net>
2024-09-22 17:46:37 +02:00
9e9347ade7
Implement automatic channel joining
Avoid the need for an administrator to join the bot to channels by
implementing a configuration option allowing the passing of channels
the bot should always join to by itself upon startup.

Signed-off-by: Georg Pfuetzenreuter <mail@georg-pfuetzenreuter.net>
2024-09-21 18:46:51 +02:00
1f41d9ac17
Replace redundant logic in Admin()
The Allowed() function already implements this loop, use it to reduce
redundant code.

Signed-off-by: Georg Pfuetzenreuter <mail@georg-pfuetzenreuter.net>
2024-09-21 17:49:39 +02:00
22b23c755e
Implement configuration file
Abstract settings which commonly differ between instances to a YAML
based configuration file to allow for easy administration without the
need for modifying the source code.

Signed-off-by: Georg Pfuetzenreuter <mail@georg-pfuetzenreuter.net>
2024-09-21 16:06:39 +02:00
3 changed files with 2 additions and 3 deletions

3
.gitignore vendored
View File

@ -8,9 +8,6 @@
*.so *.so
*.dylib *.dylib
# Normal binary, `go build`
watbot
# Test binary, build with `go test -c` # Test binary, build with `go test -c`
*.test *.test

2
count Executable file
View File

@ -0,0 +1,2 @@
wc -l osrc/watbot_*.py
wc -l *.go wat/*.go

BIN
watbot Executable file

Binary file not shown.