summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/gizmo/wasp-bannerads.el25
-rw-r--r--src/gizmo/wasp-biblicality.el3
-rw-r--r--src/gizmo/wasp-heartrate.el10
-rw-r--r--src/wasp-ai.el19
-rw-r--r--src/wasp-audio.el47
-rw-r--r--src/wasp-bus.el11
-rw-r--r--src/wasp-chat.el8
-rw-r--r--src/wasp-model.el13
-rw-r--r--src/wasp-obs.el29
-rw-r--r--src/wasp-overlay.el2
-rw-r--r--src/wasp-twitch-chat-commands.el382
-rw-r--r--src/wasp-twitch-redeems.el562
-rw-r--r--src/wasp-twitch.el6
-rw-r--r--src/wasp-user-whitelist.el6
-rw-r--r--src/wasp-utils.el6
15 files changed, 633 insertions, 496 deletions
diff --git a/src/gizmo/wasp-bannerads.el b/src/gizmo/wasp-bannerads.el
index 2586600e..70f9c8be 100644
--- a/src/gizmo/wasp-bannerads.el
+++ b/src/gizmo/wasp-bannerads.el
@@ -9,6 +9,8 @@
(require 'wasp-utils)
(require 'wasp-chat)
+(defvar w/banner-ad-block nil)
+
(defcustom w/banner-ad-buffer "*wasp-banner-ad*"
"Name of buffer used to display banner ad."
:type '(string)
@@ -32,9 +34,13 @@
(setq-local cursor-type nil)
(let* ((inhibit-read-only t))
(erase-buffer)
- (let* ((paths (f-files (w/asset "bannerads")))
- (path (w/pick-random paths)))
- (w/write (propertize "bannerad" 'display (create-image path nil nil :max-width 555 :max-height 175)))))))
+ (if w/banner-ad-block
+ (w/write "This advertisement was blocked by your adblocker")
+ (let* ((paths (f-files (w/asset "bannerads")))
+ (path (w/pick-random paths))
+ (img (create-image path nil nil :max-width 555 :max-height 175)))
+ (image-animate img nil t)
+ (w/write (propertize "bannerad" 'display img)))))))
(defvar w/banner-ad-timer nil)
(defun w/run-banner-ad-timer ()
@@ -47,5 +53,18 @@
(run-with-timer 60 nil #'w/run-banner-ad-timer)))
(w/run-banner-ad-timer)
+
+(defun w/banner-ad-block ()
+ "Toggle adblock."
+ (setq w/banner-ad-block t)
+ (w/render-banner-ad)
+ (w/model-toggle-set "adblock")
+ (run-with-timer 10 nil
+ (lambda ()
+ (setq w/banner-ad-block nil)
+ (w/model-toggle-unset "adblock")
+ (w/render-banner-ad)))
+ nil)
+
(provide 'wasp-bannerads)
;;; wasp-bannerads.el ends here
diff --git a/src/gizmo/wasp-biblicality.el b/src/gizmo/wasp-biblicality.el
index b7c46ed8..317e87f7 100644
--- a/src/gizmo/wasp-biblicality.el
+++ b/src/gizmo/wasp-biblicality.el
@@ -37,7 +37,8 @@
(let ((occs (ht-get w/bible-table (downcase (s-trim word))))
(thresh 0.6))
(if occs
- (+ thresh (/ (min occs 1000.0) (/ 1000.0 (- 1.0 thresh))))
+ ;; (+ thresh (/ (min occs 1000.0) (/ 1000.0 (- 1.0 thresh))))
+ (+ thresh (/ (min occs 10.0) (/ 10.0 (- 1.0 thresh))))
0.0))))
(defun w/bible-word-color (word)
diff --git a/src/gizmo/wasp-heartrate.el b/src/gizmo/wasp-heartrate.el
index 62994680..a195e0c5 100644
--- a/src/gizmo/wasp-heartrate.el
+++ b/src/gizmo/wasp-heartrate.el
@@ -14,10 +14,19 @@
(let ((res (shell-command-to-string "uptime")))
(string-to-number (s-trim (car (s-split "," (cadr (s-split "load average:" res))))))))
+(defun w/get-disk-usage (disk)
+ "Get the current usage percent for DISK"
+ (let ((res (shell-command-to-string (format "df %s" disk))))
+ (string-to-number (s-chop-suffix "%" (nth 4 (s-split " " (cadr (s-lines res)) t))))))
+
(defun w/get-heartrate ()
"Get the streamer's heart rate."
(* 100 (w/get-load)))
+(defun w/get-blood-pressure ()
+ "Get the streamer's blood pressure."
+ (format "%s/%s" (w/get-disk-usage "/") (w/get-disk-usage "/home")))
+
(defface w/heartrate-big
'((t
:foreground "white"
@@ -57,6 +66,7 @@
(let* ((inhibit-read-only t))
(erase-buffer)
(w/write-line (format "%3d bpm" (w/get-heartrate)) 'w/heartrate-big)
+ (w/write-line (format "blood pressure: %s" (w/get-blood-pressure)) 'w/heartrate-small)
(w/write (format "arbitrary counter: %s times" w/chat-bpm-count) 'w/heartrate-small))))
(defvar w/heartrate-timer nil)
diff --git a/src/wasp-ai.el b/src/wasp-ai.el
index e279103e..1201ca5b 100644
--- a/src/wasp-ai.el
+++ b/src/wasp-ai.el
@@ -169,15 +169,16 @@ Double-check the output to make sure it sounds normal."
(defun w/ai-transcribe (path k)
"Transcribe the audio file at PATH and pass the resulting string to K."
- (let ((request-curl-options '("-F" "model=whisper-1" "-F" "language=en")))
- (w/ai-openai-post-form
- "/v1/audio/transcriptions"
- `(("file" . ,(f-canonical path)))
- (lambda (res)
- (funcall
- k
- (-some-> res
- (ht-get "text")))))))
+ )
+ ;; (let ((request-curl-options '("-F" "model=whisper-1" "-F" "language=en")))
+ ;; (w/ai-openai-post-form
+ ;; "/v1/audio/transcriptions"
+ ;; `(("file" . ,(f-canonical path)))
+ ;; (lambda (res)
+ ;; (funcall
+ ;; k
+ ;; (-some-> res
+ ;; (ht-get "text")))))))
(provide 'wasp-ai)
;;; wasp-ai.el ends here
diff --git a/src/wasp-audio.el b/src/wasp-audio.el
index 580a3e7e..30e2bdfe 100644
--- a/src/wasp-audio.el
+++ b/src/wasp-audio.el
@@ -18,7 +18,7 @@
(defvar w/audio-record-process-current nil)
(defvar w/audio-keep-recording t)
(defvar w/audio-voice-commands nil)
-(defvar w/last-stream-transcription "")
+(defvar w/last-stream-transcription "we're going down the rabbit hole")
(defun w/tts (msg)
"Use TTS to say MSG."
@@ -44,7 +44,9 @@ If VOLUME is specified, use it to adjust the volume (100 is default)."
(defun w/stop-all-audio ()
"Stop all audio by killing mpv processes."
(interactive)
- (start-process "pkill" nil "pkill" "mpv"))
+ (setq w/audio-muzak-queue nil)
+ (start-process "pkill" nil "pkill" "mpv")
+ (start-process "pkill" nil "pkill" "muzak"))
(defun w/recorded-chatter-name? (user)
"Return non-nil if we've recorded USER's name."
@@ -148,5 +150,46 @@ USER it's your birthday today."
(setq w/audio-keep-recording nil)
(w/audio-record-end))
+(defconst w/audio-muzak-path "/home/llll/src/muzak-rs/target/release/muzak")
+(defvar w/audio-muzak-now-playing nil)
+(defvar w/audio-muzak-queue nil)
+
+(defun w/audio-muzak (user song)
+ "Play SONG by USER using muzak-rs courtesy The0x539."
+ (setq w/audio-muzak-now-playing (cons user song))
+ (w/pub '(avatar overlay muzak) (list (w/encode-string user)))
+ (let ((proc
+ (make-process
+ :name "wasp-muzak"
+ :connection-type '(pipe . pty)
+ :buffer " *wasp-muzak-log*"
+ :command (list w/audio-muzak-path "play")
+ :sentinel
+ (lambda (_ _)
+ (w/pub '(avatar overlay muzak clear) (list))
+ (setq w/audio-muzak-now-playing nil)))))
+ (process-send-string proc song)
+ (process-send-eof proc)))
+
+(defun w/audio-muzak-enqueue (user song)
+ "Enqueue a play for SONG by USER."
+ (setq w/audio-muzak-queue (-concat w/audio-muzak-queue (list (cons user song)))))
+
+(defun w/audio-muzak-update ()
+ "Keep playing songs from the queue if they exist."
+ (unless w/audio-muzak-now-playing
+ (when-let* ((entry (pop w/audio-muzak-queue)))
+ (w/audio-muzak (car entry) (cdr entry)))))
+(defvar w/audio-muzak-timer nil)
+(defun w/run-audio-muzak-timer ()
+ "Run the muzak timer."
+ (when w/audio-muzak-timer
+ (cancel-timer w/audio-muzak-timer))
+ (w/audio-muzak-update)
+ (setq
+ w/audio-muzak-timer
+ (run-with-timer 1 nil #'w/run-audio-muzak-timer)))
+(w/run-audio-muzak-timer)
+
(provide 'wasp-audio)
;;; wasp-audio.el ends here
diff --git a/src/wasp-bus.el b/src/wasp-bus.el
index aa950b29..cc75a26c 100644
--- a/src/wasp-bus.el
+++ b/src/wasp-bus.el
@@ -80,11 +80,12 @@
(defun w/pub (ev &optional d)
"Publish the data D to the event EV."
- (process-send-string
- w/bus-process
- (s-concat
- (format "%S" `(pub ,ev ,@d))
- "\n")))
+ (let ((s (s-concat (format "%S" `(pub ,ev ,@d)) "\n")))
+ (w/write-log (format "sending: %s" s))
+ (process-send-string
+ w/bus-process
+ s
+ )))
(defun w/sub-all ()
"Subscribe to all events in `w/bus-event-handlers'."
diff --git a/src/wasp-chat.el b/src/wasp-chat.el
index 3cf73899..10931b8d 100644
--- a/src/wasp-chat.el
+++ b/src/wasp-chat.el
@@ -289,8 +289,16 @@ Optionally, return the buffer NM in chat mode."
(when (w/. biblicality msg)
(let* ((wwidth (- (window-total-width (get-buffer-window (current-buffer))) 3))
(bible-button-text (format "[biblicality %.2f]" (w/. biblicality msg)))
+ ;; (bible-button-text (format "[pollicality %.2f]" (w/. biblicality msg)))
(msgwidth (line-beginning-position))
(lines (+ 1 (/ msgwidth wwidth))))
+
+ (w/pub '(avatar overlay chat)
+ (list
+ (w/encode-string (w/. text msg))
+ (format "%s" (w/unix-time))
+ (format "%s" (or (w/. biblicality msg) 0.0))))
+
(insert
(propertize
" " 'display
diff --git a/src/wasp-model.el b/src/wasp-model.el
index 521b3686..321f7dae 100644
--- a/src/wasp-model.el
+++ b/src/wasp-model.el
@@ -47,6 +47,9 @@
(w/pub '(avatar reset))
;; (w/model-region-color "eyes" (color-values "gold"))
;; (w/model-region-word "eyes" "GOLDEN")
+ ;; (w/model-region-video "hair" "https://www.twitch.tv/kamijoan")
+ ;; (w/model-region-video "hair" "https://www.twitch.tv/kiwidancing")
+ (w/model-region-video "hair" "https://www.youtube.com/watch?v=FtutLA63Cp8")
)
(defun w/model-toggle (toggle)
@@ -54,6 +57,16 @@
(w/model-record-change)
(w/pub '(avatar toggle) (list toggle)))
+(defun w/model-toggle-set (toggle)
+ "Set TOGGLE on model."
+ (w/model-record-change)
+ (w/pub '(avatar toggle set) (list toggle)))
+
+(defun w/model-toggle-unset (toggle)
+ "Unset TOGGLE on model."
+ (w/model-record-change)
+ (w/pub '(avatar toggle unset) (list toggle)))
+
(defun w/model-background-text (msg)
"Change the background text of the model to MSG."
(let* ((cleanmsg (s-trim (w/clean-string msg)))
diff --git a/src/wasp-obs.el b/src/wasp-obs.el
index 0919eef4..35ead18d 100644
--- a/src/wasp-obs.el
+++ b/src/wasp-obs.el
@@ -89,6 +89,11 @@ Optionally, change text to MSG."
"Toggle the debate topic."
(w/pub '(monitor obs toggle) (list "Main" "Debate Topic")))
+(defun w/obs-toggle-spatiotemporal-clarity ()
+ "Toggle the shader clarity effect."
+ (w/model-toggle "shaderclarity")
+ (w/pub '(monitor obs toggle) (list "Main" "Mic")))
+
(w/defstruct
w/obs-toggle
toggle
@@ -103,17 +108,19 @@ Optionally, change text to MSG."
(defvar w/obs-toggles
(list
- (cons 'modclonk (w/make-obs-toggle :toggle #'w/obs-toggle-modclonk :reset 11))
- (cons 'live-reaction (w/make-obs-toggle :toggle #'w/obs-toggle-live-reaction :reset 17))
- (cons 'live-friend-reaction (w/make-obs-toggle :toggle #'w/obs-toggle-live-friend-reaction :reset 17))
- (cons 'thug-life (w/make-obs-toggle :toggle #'w/obs-toggle-thug-life :reset 17))
- (cons 'intj-stare (w/make-obs-toggle :toggle #'w/obs-toggle-intj-stare :reset 17))
- (cons 'critical-hit (w/make-obs-toggle :toggle #'w/obs-toggle-critical-hit :reset 3))
- (cons 'clickbait (w/make-obs-toggle :toggle #'w/obs-toggle-clickbait :reset 31))
- (cons 'chase-dreams (w/make-obs-toggle :toggle #'w/obs-toggle-chase-dreams :reset 31))
- (cons 'total-clarity (w/make-obs-toggle :toggle #'w/obs-toggle-total-clarity :reset 10))
- (cons 'activate-nixos (w/make-obs-toggle :toggle #'w/obs-toggle-activate-nixos :reset 31))
- (cons 'pharaohs-curse (w/make-obs-toggle :toggle (lambda () (w/model-toggle "sand")) :reset 20))))
+ (cons 'modclonk (w/make-obs-toggle :toggle #'w/obs-toggle-modclonk :reset 11))
+ (cons 'live-reaction (w/make-obs-toggle :toggle #'w/obs-toggle-live-reaction :reset 17))
+ (cons 'live-friend-reaction (w/make-obs-toggle :toggle #'w/obs-toggle-live-friend-reaction :reset 17))
+ (cons 'thug-life (w/make-obs-toggle :toggle #'w/obs-toggle-thug-life :reset 17))
+ (cons 'intj-stare (w/make-obs-toggle :toggle #'w/obs-toggle-intj-stare :reset 17))
+ (cons 'critical-hit (w/make-obs-toggle :toggle #'w/obs-toggle-critical-hit :reset 3))
+ (cons 'clickbait (w/make-obs-toggle :toggle #'w/obs-toggle-clickbait :reset 31))
+ (cons 'chase-dreams (w/make-obs-toggle :toggle #'w/obs-toggle-chase-dreams :reset 31))
+ (cons 'total-clarity (w/make-obs-toggle :toggle #'w/obs-toggle-total-clarity :reset 10))
+ (cons 'activate-nixos (w/make-obs-toggle :toggle #'w/obs-toggle-activate-nixos :reset 31))
+ (cons 'pharaohs-curse (w/make-obs-toggle :toggle (lambda () (w/model-toggle "sand")) :reset 20))
+ (cons 'spatiotemporal-clarity (w/make-obs-toggle :toggle #'w/obs-toggle-spatiotemporal-clarity :reset 7))
+ ))
(defun w/obs-activate-toggle (tnm &rest args)
"Pass ARGS to the callback for toggle symbol TNM and start its timer."
diff --git a/src/wasp-overlay.el b/src/wasp-overlay.el
index e71ff0ab..23786453 100644
--- a/src/wasp-overlay.el
+++ b/src/wasp-overlay.el
@@ -42,7 +42,7 @@
(defun w/overlay-decode-shorthand-bml (s k)
"Decode the shorthand BulletML string S.
Pass the resulting BulletML XML string to K."
- (w/write-log s)
+ ;; (w/write-log s)
(w/prod-get-raw
(format "/api/yamame?input=%s" (url-encode-url s))
(lambda (data)
diff --git a/src/wasp-twitch-chat-commands.el b/src/wasp-twitch-chat-commands.el
index 2cca2158..33435d7f 100644
--- a/src/wasp-twitch-chat-commands.el
+++ b/src/wasp-twitch-chat-commands.el
@@ -11,197 +11,199 @@
(require 'wasp-pronunciation)
(setq
- w/twitch-chat-commands
- (list
- (cons
- "!commands"
- (lambda (_ _)
- (w/twitch-say
- (s-concat
- "Available commands: "
- (s-join " " (--filter (s-contains? "!" it) (-map #'car w/twitch-chat-commands)))))))
- (cons "MRBEAST" (lambda (_ _) (soundboard//play-clip "mrbeast.mp3")))
- (cons "NICECOCK" (lambda (_ _) (soundboard//play-clip "pantsintoashes.mp3")))
- (cons "hexadiCoding" (lambda (_ _) (soundboard//play-clip "developers.ogg")))
- (cons "ProgrammingTime" (lambda (_ _) (soundboard//play-clip "emacslisp.ogg")))
- (cons
- "roguelike"
- (lambda (user _)
- (w/twitch-say
- (if (= 0 (random 20))
- (format "@%s that is a roguelike :3" user)
- (format "@%s that's not a roguelike" user)))))
- (cons "arch btw" (lambda (_ _) (w/twitch-say "I use nix btw")))
- (cons "!advent" (lambda (_ _) (w/twitch-say "Join our private leaderboard: 3307583-b61f237c")))
- (cons "!discord" (lambda (_ _) (w/twitch-say "https://discord.gg/f4JTbgN7St")))
- (cons "discord IRC" (lambda (_ _) (w/twitch-say "https://discord.gg/f4JTbgN7St")))
- (cons "discord irc" (lambda (_ _) (w/twitch-say "https://discord.gg/f4JTbgN7St")))
- (cons "Discord IRC" (lambda (_ _) (w/twitch-say "https://discord.gg/f4JTbgN7St")))
- (cons "Discord irc" (lambda (_ _) (w/twitch-say "https://discord.gg/f4JTbgN7St")))
- (cons "Joel" (lambda (_ _) (cl-incf w/chat-joel-count) (w/chat-update-header-line)))
- (cons "+2" (lambda (_ _) (cl-incf w/chat-plus2-count) (w/chat-update-header-line)))
- (cons "-2" (lambda (_ _) (cl-incf w/chat-minus2-count) (w/chat-update-header-line)))
- (cons "ICANT" (lambda (_ _) (cl-incf w/chat-icant-count) (w/chat-update-header-line)))
- (cons "bpm" (lambda (_ _) (cl-incf w/chat-bpm-count)))
- (cons "BPM" (lambda (_ _) (cl-incf w/chat-bpm-count)))
- (cons "heartrate" (lambda (_ _) (cl-incf w/chat-bpm-count)))
- (cons "Heartrate" (lambda (_ _) (cl-incf w/chat-bpm-count)))
- (cons "heart" (lambda (_ _) (cl-incf w/chat-bpm-count)))
- (cons "Heart" (lambda (_ _) (cl-incf w/chat-bpm-count)))
- (cons "!menu" (lambda (_ _) (w/twitch-say "https://secure.colonq.computer/menu")))
- (cons "!guy" (lambda (_ _) (w/twitch-say "[🌙] it worked")))
- (cons "!littleguy" (lambda (_ _) (w/twitch-say "[🌙] it worked")))
- (cons "!irc" (lambda (_ _) (w/twitch-say "#cyberspace on IRC at colonq.computer:26697 (over TLS)")))
- (cons "IRC" (lambda (_ _) (w/twitch-say "#cyberspace on IRC at colonq.computer:26697 (over TLS)")))
+ w/twitch-chat-commands
+ (list
+ (cons
+ "!commands"
+ (lambda (_ _)
+ (w/twitch-say
+ (s-concat
+ "Available commands: "
+ (s-join " " (--filter (s-contains? "!" it) (-map #'car w/twitch-chat-commands)))))))
+ (cons "MRBEAST" (lambda (_ _) (soundboard//play-clip "mrbeast.mp3")))
+ (cons "NICECOCK" (lambda (_ _) (soundboard//play-clip "pantsintoashes.mp3")))
+ (cons "hexadiCoding" (lambda (_ _) (soundboard//play-clip "developers.ogg")))
+ (cons "ProgrammingTime" (lambda (_ _) (soundboard//play-clip "emacslisp.ogg")))
+ (cons
+ "roguelike"
+ (lambda (user _)
+ (w/twitch-say
+ (if (= 0 (random 20))
+ (format "@%s that is a roguelike :3" user)
+ (format "@%s that's not a roguelike" user)))))
+ (cons "arch btw" (lambda (_ _) (w/twitch-say "I use nix btw")))
+ (cons "!advent" (lambda (_ _) (w/twitch-say "Join our private leaderboard: 3307583-b61f237c")))
+ (cons "!discord" (lambda (_ _) (w/twitch-say "https://discord.gg/f4JTbgN7St")))
+ ;; (cons "discord IRC" (lambda (_ _) (w/twitch-say "https://discord.gg/f4JTbgN7St")))
+ ;; (cons "discord irc" (lambda (_ _) (w/twitch-say "https://discord.gg/f4JTbgN7St")))
+ ;; (cons "Discord IRC" (lambda (_ _) (w/twitch-say "https://discord.gg/f4JTbgN7St")))
+ ;; (cons "Discord irc" (lambda (_ _) (w/twitch-say "https://discord.gg/f4JTbgN7St")))
+ (cons "!irc" (lambda (_ _) (w/twitch-say "#cyberspace on IRC at colonq.computer:26697 (over TLS)")))
+ ;; (cons "IRC" (lambda (_ _) (w/twitch-say "#cyberspace on IRC at colonq.computer:26697 (over TLS)")))
+ (cons "Joel" (lambda (_ _) (cl-incf w/chat-joel-count) (w/chat-update-header-line)))
+ (cons "+2" (lambda (_ _) (cl-incf w/chat-plus2-count) (w/chat-update-header-line)))
+ (cons "-2" (lambda (_ _) (cl-incf w/chat-minus2-count) (w/chat-update-header-line)))
+ (cons "ICANT" (lambda (_ _) (cl-incf w/chat-icant-count) (w/chat-update-header-line)))
+ (cons "bpm" (lambda (_ _) (cl-incf w/chat-bpm-count)))
+ (cons "BPM" (lambda (_ _) (cl-incf w/chat-bpm-count)))
+ (cons "heartrate" (lambda (_ _) (cl-incf w/chat-bpm-count)))
+ (cons "Heartrate" (lambda (_ _) (cl-incf w/chat-bpm-count)))
+ (cons "heart" (lambda (_ _) (cl-incf w/chat-bpm-count)))
+ (cons "Heart" (lambda (_ _) (cl-incf w/chat-bpm-count)))
+ (cons "!menu" (lambda (_ _) (w/twitch-say "https://secure.colonq.computer/menu")))
+ (cons "!guy" (lambda (_ _) (w/twitch-say "[🌙] it worked")))
+ (cons "!littleguy" (lambda (_ _) (w/twitch-say "[🌙] it worked")))
- (cons "!today" (lambda (_ _) (w/twitch-say (s-trim (w/slurp "~/today.txt")))))
- (cons "!schedule" (lambda (_ _) (w/twitch-say "https://twitch.tv/LCOLONQ/schedule")))
- (cons "!bingo" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer/~prod/toy/bingo/")))
- (cons "!music" (lambda (_ _) (w/twitch-say "we do not play music because it can be distracting; however you can listen to the official OST at https://vgmusic.fm :3")))
- (cons
- "!music"
- (lambda (_ _) (w/twitch-say "alternatively https://www.youtube.com/playlist?list=PLQ_Vw7ACol3CN58_osDkbeKa14Hk-N-TZ")))
- (cons
- "!fish"
- (lambda (_ _)
- (w/twitch-say (shell-command-to-string "fishing"))))
- (cons "!nc" (lambda (_ _) (w/twitch-say "try: \"nc colonq.computer 31340\", if nc doesn't work try ncat or telnet")))
- (cons
- "!oomfie"
- (lambda (_ _)
- (soundboard//play-clip "oomfie.ogg")
- (w/twitch-say "hi!!!!!!!")))
- (cons "!helloiloveyou" (lambda (_ _) (w/twitch-say "hello i love you")))
- (cons "!pronunciation" (lambda (_ _) (w/twitch-say (w/pronuciation))))
- ;; (cons "!jetsWave" (lambda (_ _) (fig//twitch-say (fig/slurp "jetsWave.txt"))))
- ;; (cons "!forth" (lambda (_ _) (fig//twitch-say "https://github.com/lcolonq/giving")))
- (cons "!oub" (lambda (_ _) (w/twitch-say "https://oub.colonq.computer")))
- (cons "!cellar" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer/~llll/cellar/index.html")))
- (cons "!game" (lambda (_ _) (w/twitch-say "https://oub.colonq.computer")))
- (cons "!voidstranger" (lambda (_ _) (w/twitch-say "https://store.steampowered.com/app/2121980/Void_Stranger/")))
- (cons "!pubnix" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer")))
- (cons "!ring" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer")))
- (cons "!webring" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer")))
- (cons "!animeguide" (lambda (_ _) (w/twitch-say "https://nixos-and-flakes.thiscute.world/introduction")))
- (cons "!greencircle" (lambda (_ _) (w/twitch-say "https://greencircle.live")))
- (cons "!circle" (lambda (_ _) (w/twitch-say "https://greencircle.live")))
- (cons "!doujincircle" (lambda (_ _) (w/twitch-say "https://greencircle.live")))
- (cons "!tsuki" (lambda (_ _) (w/twitch-say "https://forum.tsuki.games")))
- (cons "!sponsor" (lambda (_ _) (w/twitch-say "Like what you see? Don't forget to download GNU Emacs at https://www.gnu.org/software/emacs/?code=LCOLONQ")))
- (cons "!specs" (lambda (_ _) (w/twitch-say "Editor: evil-mode, WM: EXWM, OS: NixOS, hardware: shit laptop")))
- (cons "!coverage" (lambda (_ _) (w/twitch-say (format "Test coverage: %s%%" (random 100)))))
- (cons "!learnprogramming" (lambda (_ _) (w/twitch-say "1) program")))
- (cons "!github" (lambda (_ _) (w/twitch-say "https://github.com/lcolonq")))
- (cons "!language" (lambda (_ _) (w/twitch-say "probably emacs lisp or maybe rust")))
- (cons "!onlyfans" (lambda (_ _) (soundboard//play-clip "pornhub.mp3")))
- (cons "!throne" (lambda (_ _) (w/twitch-say "xdding")))
- (cons "!vim" (lambda (_ _) (w/twitch-say "vi is the best text editor, emacs is the best operating system")))
- (cons "!emacs" (lambda (_ _) (w/twitch-say "i've tried everything else emacs is best girl")))
- (cons "!bells" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer/~bezelea/bells/ and https://pub.colonq.computer/~prod/toy/dbkai/")))
- (cons "!help" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer/~prod/toy/glossary/")))
- (cons
- "!boost"
- (lambda (user _)
- (w/twitch-say (format "boost power for @%s: %s" user (alist-get :boost w/user-current)))))
- (cons
- "!faction"
- (lambda (user _)
- (w/twitch-say (format "faction for %s: %s" user (alist-get :faction w/user-current)))))
- (cons "!thanks" (lambda (user _) (w/twitch-say (format "thank you %s!" user))))
- (cons "!bible" (lambda (_ _) (w/twitch-say "https://www.youtube.com/watch?v=G5u23bh29hI")))
- (cons "!drink" (lambda (_ _) (w/twitch-say "its watah im drinkin it")))
- (cons
- "!lore"
- (lambda (_ _)
- (w/ai
- "ITEM"
- (lambda (msg) (w/twitch-say msg))
- "Please produce a Dark Souls style item name and description related to LCOLONQ. Please limit your response to one sentence maximum. The sentence should be vague and incorporate archaic words that are not commonly used. LCOLONQ is a spirit that lives inside the computer. LCOLONQ is associated with: the moon, snakes, the color grey, dolls and puppets, amber, the wind, and GNU Emacs. The description should mostly describe the item, but with vague insinuations about the true nature of LCOLONQ."
- "ITEM"
- "Ring of Favor and Protection - A ring symbolizing the favor and protection of the goddess Fina, known in legend to possess fateful beauty.")))
- ;; (cons "!geisercounter" (lambda (_ _) (fig//twitch-say (format "The Geiser counter beeps %s times" (fig//geiser-counter)))))
- (cons
- "!8ball"
- (lambda (user inp)
- (let ((trimmed (s-trim (s-replace "!8ball" "" inp))))
- (w/8ball
- trimmed
- (lambda (answer)
- (w/twitch-say (format "@%s 8ball says: %s" user answer)))))))
- (cons
- "!bookrec"
- (lambda (_ _)
- (w/user-get
- "__books__"
- (lambda (books)
- (let ((choice (w/pick-random books)))
- (w/twitch-say (format "%s (recommended by %s)" (car choice) (cdr choice))))))))
- (cons
- "!quote"
- (lambda (_ _)
- (w/user-get
- "__quotes__"
- (lambda (books)
- (let ((choice (w/pick-random books)))
- (w/twitch-say (format "%s: %s" (cdr choice) (car choice))))))))
- (cons
- "!leaderboard"
- (lambda (_ _)
- (let* ((user-scores (-filter #'cdr (--map (when (and (listp it) (listp (cdr it))) (cons (car it) (alist-get :boost (cdr it)))) (ht->alist w/user-cache))))
- (sorted (-sort (-on #'> #'cdr) user-scores))
- (leaders (-take 5 sorted)))
- (w/twitch-say (s-join ", " (--map (format "%s: %s" (car it) (cdr it)) leaders))))))
- (cons
- "draobredael!"
- (lambda (_ _)
- (let* ((user-scores (-filter #'cdr (--map (when (and (listp it) (listp (cdr it))) (cons (car it) (alist-get :boost (cdr it)))) (ht->alist w/user-cache))))
- (sorted (-sort (-on #'< #'cdr) user-scores))
- (leaders (-take 5 sorted)))
- (w/twitch-say (s-join ", " (--map (format "%s: %s" (reverse (car it)) (cdr it)) leaders))))))
- (cons
- "!resolution"
- (lambda (user inp)
- (let ((trimmed (s-trim (s-replace "!resolution" "" inp))))
- (if (string-empty-p trimmed)
- (w/write-chat-event "You gotta put what your resolution is.")
- (w/write-chat-event (format "%s RESOLVES: %s" (s-upcase user) trimmed))
- (setf (alist-get :resolution2025 w/user-current) trimmed)))))
- ;; (cons "!addbookrec"
- ;; (lambda (user inp)
- ;; (let ((trimmed (s-trim (s-replace "!addbookrec" "" inp))))
- ;; (fig//write-chat-event (format "%s recommends: %s" user trimmed))
- ;; (fig//add-recommended-book user trimmed))))
- ;; (cons "!quote"
- ;; (lambda (_ _)
- ;; (let ((choice (nth (random (length fig/quotes)) fig/quotes)))
- ;; (fig//twitch-say (format "%s: %s" (cdr choice) (car choice))))))
- ;; (cons "!addquote"
- ;; (lambda (user inp)
- ;; (let ((trimmed (s-trim (s-replace "!addquote" "" inp))))
- ;; (fig//write-chat-event (format "%s saves quote: %s" user trimmed))
- ;; (fig//add-quote user trimmed))))
- ;; (cons "!twitter"
- ;; (lambda (_ _)
- ;; (fig/ask "How do you feel about Twitter? Should viewers follow LCOLONQ on Twitter?" #'fig/say)
- ;; (fig//twitch-say "https://twitter.com/LCOLONQ")))
- ;; ;; (cons "!aoc" (lambda (_ _) (fig//twitch-say "Join our leaderboard: 3307583-b61f237c")))
- ;; (cons "!roll" (lambda (user _) (fig//twitch-say (fig//character-to-string (fig//roll-character user)))))
- ;; (cons
- ;; (cons
- ;; "!vippers"
- ;; (lambda (_ _)
- ;; (let ((vipperstring (s-join ", " (fig//shuffle-seq fig//twitch-vip-list))))
- ;; (fig//twitch-say (seq-take vipperstring 450)))
- ;; (fig//twitch-get-vip-list)))
- ;; (cons "!levelup"
- ;; (lambda (user _)
- ;; (fig//update-db-character
- ;; user
- ;; (lambda (c)
- ;; (cl-incf (fig//rpg-character-level c))
- ;; c))
- ;; (fig//twitch-say (fig//character-to-string (fig//get-db-character user)))))
- ))
+ (cons "!today" (lambda (_ _) (w/twitch-say (s-trim (w/slurp "~/today.txt")))))
+ (cons "!schedule" (lambda (_ _) (w/twitch-say "https://twitch.tv/LCOLONQ/schedule")))
+ (cons "!bingo" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer/~prod/toy/bingo/")))
+ (cons "!music" (lambda (_ _) (w/twitch-say "we do not play music because it can be distracting; however you can listen to the official OST at https://vgmusic.fm :3")))
+ (cons "!mrgreen" (lambda (_ _) (w/twitch-say "lcolonGreen https://p.yusukekamiyamane.com/ lcolonGreen")))
+ (cons
+ "!music"
+ (lambda (_ _) (w/twitch-say "alternatively https://www.youtube.com/playlist?list=PLQ_Vw7ACol3CN58_osDkbeKa14Hk-N-TZ")))
+ (cons
+ "!fish"
+ (lambda (_ _)
+ (w/twitch-say (shell-command-to-string "fishing"))))
+ (cons "!nc" (lambda (_ _) (w/twitch-say "try: \"nc colonq.computer 31340\", if nc doesn't work try ncat or telnet")))
+ (cons
+ "!oomfie"
+ (lambda (_ _)
+ (soundboard//play-clip "oomfie.ogg")
+ (w/twitch-say "hi!!!!!!!")))
+ (cons "!helloiloveyou" (lambda (_ _) (w/twitch-say "hello i love you")))
+ (cons "!pronunciation" (lambda (_ _) (w/twitch-say (w/pronuciation))))
+ ;; (cons "!jetsWave" (lambda (_ _) (fig//twitch-say (fig/slurp "jetsWave.txt"))))
+ ;; (cons "!forth" (lambda (_ _) (fig//twitch-say "https://github.com/lcolonq/giving")))
+ (cons "!oub" (lambda (_ _) (w/twitch-say "https://oub.colonq.computer")))
+ (cons "!cellar" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer/~llll/cellar/index.html")))
+ (cons "!game" (lambda (_ _) (w/twitch-say "https://oub.colonq.computer")))
+ (cons "!voidstranger" (lambda (_ _) (w/twitch-say "https://store.steampowered.com/app/2121980/Void_Stranger/")))
+ (cons "!pubnix" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer")))
+ (cons "!ring" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer")))
+ (cons "!webring" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer")))
+ (cons "!animeguide" (lambda (_ _) (w/twitch-say "https://nixos-and-flakes.thiscute.world/introduction")))
+ (cons "!greencircle" (lambda (_ _) (w/twitch-say "https://greencircle.live")))
+ (cons "!circle" (lambda (_ _) (w/twitch-say "https://greencircle.live")))
+ (cons "!doujincircle" (lambda (_ _) (w/twitch-say "https://greencircle.live")))
+ (cons "!tsuki" (lambda (_ _) (w/twitch-say "https://forum.tsuki.games")))
+ (cons "!sponsor" (lambda (_ _) (w/twitch-say "Like what you see? Don't forget to download GNU Emacs at https://www.gnu.org/software/emacs/?code=LCOLONQ")))
+ (cons "!specs" (lambda (_ _) (w/twitch-say "Editor: evil-mode, WM: EXWM, OS: NixOS, hardware: shit laptop")))
+ (cons "!coverage" (lambda (_ _) (w/twitch-say (format "Test coverage: %s%%" (random 100)))))
+ (cons "!learnprogramming" (lambda (_ _) (w/twitch-say "1) program")))
+ (cons "!github" (lambda (_ _) (w/twitch-say "https://github.com/lcolonq")))
+ (cons "!language" (lambda (_ _) (w/twitch-say "probably emacs lisp or maybe rust")))
+ (cons "!onlyfans" (lambda (_ _) (soundboard//play-clip "pornhub.mp3")))
+ (cons "!throne" (lambda (_ _) (w/twitch-say "xdding")))
+ (cons "!vim" (lambda (_ _) (w/twitch-say "vi is the best text editor, emacs is the best operating system")))
+ (cons "!emacs" (lambda (_ _) (w/twitch-say "i've tried everything else emacs is best girl")))
+ (cons "!bells" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer/~bezelea/bells/ and https://pub.colonq.computer/~prod/toy/dbkai/")))
+ (cons "!shader" (lambda (_ _) (w/twitch-say "https://secure.colonq.computer/throwshade")))
+ (cons "!help" (lambda (_ _) (w/twitch-say "https://pub.colonq.computer/~prod/toy/glossary/")))
+ (cons
+ "!boost"
+ (lambda (user _)
+ (w/twitch-say (format "boost power for @%s: %s" user (alist-get :boost w/user-current)))))
+ (cons
+ "!faction"
+ (lambda (user _)
+ (w/twitch-say (format "faction for %s: %s" user (alist-get :faction w/user-current)))))
+ (cons "!thanks" (lambda (user _) (w/twitch-say (format "thank you %s!" user))))
+ (cons "!bible" (lambda (_ _) (w/twitch-say "https://www.youtube.com/watch?v=G5u23bh29hI")))
+ (cons "!drink" (lambda (_ _) (w/twitch-say "its watah im drinkin it")))
+ (cons
+ "!lore"
+ (lambda (_ _)
+ (w/ai
+ "ITEM"
+ (lambda (msg) (w/twitch-say msg))
+ "Please produce a Dark Souls style item name and description related to LCOLONQ. Please limit your response to one sentence maximum. The sentence should be vague and incorporate archaic words that are not commonly used. LCOLONQ is a spirit that lives inside the computer. LCOLONQ is associated with: the moon, snakes, the color grey, dolls and puppets, amber, the wind, and GNU Emacs. The description should mostly describe the item, but with vague insinuations about the true nature of LCOLONQ."
+ "ITEM"
+ "Ring of Favor and Protection - A ring symbolizing the favor and protection of the goddess Fina, known in legend to possess fateful beauty.")))
+ ;; (cons "!geisercounter" (lambda (_ _) (fig//twitch-say (format "The Geiser counter beeps %s times" (fig//geiser-counter)))))
+ (cons
+ "!8ball"
+ (lambda (user inp)
+ (let ((trimmed (s-trim (s-replace "!8ball" "" inp))))
+ (w/8ball
+ trimmed
+ (lambda (answer)
+ (w/twitch-say (format "@%s 8ball says: %s" user answer)))))))
+ (cons
+ "!bookrec"
+ (lambda (_ _)
+ (w/user-get
+ "__books__"
+ (lambda (books)
+ (let ((choice (w/pick-random books)))
+ (w/twitch-say (format "%s (recommended by %s)" (car choice) (cdr choice))))))))
+ (cons
+ "!quote"
+ (lambda (_ _)
+ (w/user-get
+ "__quotes__"
+ (lambda (books)
+ (let ((choice (w/pick-random books)))
+ (w/twitch-say (format "%s: %s" (cdr choice) (car choice))))))))
+ (cons
+ "!leaderboard"
+ (lambda (_ _)
+ (let* ((user-scores (-filter #'cdr (--map (when (and (listp it) (listp (cdr it))) (cons (car it) (alist-get :boost (cdr it)))) (ht->alist w/user-cache))))
+ (sorted (-sort (-on #'> #'cdr) user-scores))
+ (leaders (-take 5 sorted)))
+ (w/twitch-say (s-join ", " (--map (format "%s: %s" (car it) (cdr it)) leaders))))))
+ (cons
+ "draobredael!"
+ (lambda (_ _)
+ (let* ((user-scores (-filter #'cdr (--map (when (and (listp it) (listp (cdr it))) (cons (car it) (alist-get :boost (cdr it)))) (ht->alist w/user-cache))))
+ (sorted (-sort (-on #'< #'cdr) user-scores))
+ (leaders (-take 5 sorted)))
+ (w/twitch-say (s-join ", " (--map (format "%s: %s" (reverse (car it)) (cdr it)) leaders))))))
+ (cons
+ "!resolution"
+ (lambda (user inp)
+ (let ((trimmed (s-trim (s-replace "!resolution" "" inp))))
+ (if (string-empty-p trimmed)
+ (w/write-chat-event "You gotta put what your resolution is.")
+ (w/write-chat-event (format "%s RESOLVES: %s" (s-upcase user) trimmed))
+ (setf (alist-get :resolution2025 w/user-current) trimmed)))))
+ ;; (cons "!addbookrec"
+ ;; (lambda (user inp)
+ ;; (let ((trimmed (s-trim (s-replace "!addbookrec" "" inp))))
+ ;; (fig//write-chat-event (format "%s recommends: %s" user trimmed))
+ ;; (fig//add-recommended-book user trimmed))))
+ ;; (cons "!quote"
+ ;; (lambda (_ _)
+ ;; (let ((choice (nth (random (length fig/quotes)) fig/quotes)))
+ ;; (fig//twitch-say (format "%s: %s" (cdr choice) (car choice))))))
+ ;; (cons "!addquote"
+ ;; (lambda (user inp)
+ ;; (let ((trimmed (s-trim (s-replace "!addquote" "" inp))))
+ ;; (fig//write-chat-event (format "%s saves quote: %s" user trimmed))
+ ;; (fig//add-quote user trimmed))))
+ ;; (cons "!twitter"
+ ;; (lambda (_ _)
+ ;; (fig/ask "How do you feel about Twitter? Should viewers follow LCOLONQ on Twitter?" #'fig/say)
+ ;; (fig//twitch-say "https://twitter.com/LCOLONQ")))
+ ;; ;; (cons "!aoc" (lambda (_ _) (fig//twitch-say "Join our leaderboard: 3307583-b61f237c")))
+ ;; (cons "!roll" (lambda (user _) (fig//twitch-say (fig//character-to-string (fig//roll-character user)))))
+ ;; (cons
+ ;; (cons
+ ;; "!vippers"
+ ;; (lambda (_ _)
+ ;; (let ((vipperstring (s-join ", " (fig//shuffle-seq fig//twitch-vip-list))))
+ ;; (fig//twitch-say (seq-take vipperstring 450)))
+ ;; (fig//twitch-get-vip-list)))
+ ;; (cons "!levelup"
+ ;; (lambda (user _)
+ ;; (fig//update-db-character
+ ;; user
+ ;; (lambda (c)
+ ;; (cl-incf (fig//rpg-character-level c))
+ ;; c))
+ ;; (fig//twitch-say (fig//character-to-string (fig//get-db-character user)))))
+ ))
(provide 'wasp-twitch-chat-commands)
;;; wasp-twitch-chat-commands.el ends here
diff --git a/src/wasp-twitch-redeems.el b/src/wasp-twitch-redeems.el
index c673430b..bf7a352b 100644
--- a/src/wasp-twitch-redeems.el
+++ b/src/wasp-twitch-redeems.el
@@ -22,277 +22,299 @@
(defvar w/twitch-redeem-sound-last 0)
(setf
- w/twitch-redeems
- (list
- (list
- "lurker check in" 1
- (lambda (user _)
- (w/write-chat-event (format "%s is lurking" user))))
- (list
- "mental clarity" 1
- (lambda (user _)
- (w/write-chat-event (format "%s established mental clarity" user))
- (w/stop-all-audio)))
- (list
- "BOOST" 1
- (lambda (user _)
- (unless (-contains? w/twitch-boosters user)
- (add-to-list 'w/twitch-boosters user)
- (soundboard//play-clip "yougotboostpower.ogg")
- (w/write-chat-event (s-concat user " boosted their boost number"))
- (cl-incf (alist-get :boost w/user-current 0)))))
- (list
- "TSOOB" 1
- (lambda (user _)
- (unless (-contains? w/twitch-tsoobers user)
- (add-to-list 'w/twitch-tsoobers user)
- (soundboard//play-clip "rewoptsoobtoguoy.ogg" 140)
- (w/write-chat-event (s-reverse (s-concat user " boosted their boost number")))
- (cl-decf (alist-get :boost w/user-current 0)))))
- (list
- "submit headline" 1
- (lambda (user inp)
- (w/write-chat-event (format "%s submitted a headline: %s" user inp))
- (w/glossary-record inp)
- (w/friend-journalism user inp)))
- (list
- "cycle gizmos" 1
- (lambda (user _)
- (w/write-chat-event (format "%s cycled the gizmos" user))
- (w/gizmo-cycle)))
- (list
- "allow streamer to drink" 1
- (lambda (user _)
- (w/write-chat-event (format "%s allowed the streamer to \"drink\"" user))))
- (list
- "deslug" 1
- (lambda (user _)
- (w/write-chat-event (format "%s inverted slug" user))))
- (list
- "talk to clone" 2
- (lambda (user inp)
- (push (cons user inp) w/twitch-chat-history)
- (let ((w/twitch-chat-history (list (cons user inp)))
- (w/last-stream-transcription "")
- (ping (w/message-ping inp)))
- (w/write-chat-event (s-concat user " asks clone: " inp))
- (w/fake-chatter-run
- (w/pick-random
- (or
- (and ping (w/dna-user-clones ping))
- (w/dna-user-clones user)
- w/fake-chatters))))))
- (list
- "spinne" 3
- (lambda (user _)
- (w/write-chat-event (s-concat user " activates the spinne cyclle"))
- (w/model-toggle "spin")))
- (list
- "forsen" 3
- (lambda (user _)
- (let ((cur (float-time)))
- (when (> (- cur w/twitch-redeem-sound-last) 2)
- (w/write-chat-event (s-concat user " loudly exclaims forsenE"))
- (soundboard//play-clip "cave3.ogg" 75)
- (w/model-toggle "forsen")
- (setq w/twitch-redeem-sound-last cur)))))
- (list
- "SEASICKNESS GENERATOR" 3
- (lambda (user _)
- (w/write-chat-event (s-concat user " is a salty sea dog"))
- (w/model-toggle "zoom_wave")))
- (list
- "The Pharaoh's Curse" 3
- (lambda (user _)
- (w/write-chat-event (format "%s drew the ire of the Pharaoh upon me" user))
- (w/obs-activate-toggle 'pharaohs-curse)
- ))
- (list
- "pursue idol dream" 3
- (lambda (user _)
- (w/write-chat-event (format "Helping %s pursue their idol dream~" user))
- (w/obs-activate-toggle 'chase-dreams)
- (w/model-region-user-avatar "hair" user)))
- (list
- "INTJ stare" 3
- (lambda (user _)
- (w/write-chat-event (format "%s suggested a little more sodium chloride next time" user))
- (w/obs-activate-toggle 'intj-stare)))
- (list
- "Live LCOLONQ Reaction" 3
- (lambda (user _)
- (w/write-chat-event (format "%s demanded extremely \"hype\" reactions, &c." user))
- (w/obs-activate-toggle 'live-reaction)))
- (list
- "Live friend Reaction" 3
- (lambda (user _)
- (w/write-chat-event (format "%s demanded extremely \"hype\" reactions, &c. but from \"friend\"!?" user))
- (w/obs-activate-toggle 'live-friend-reaction)))
- (list
- "bells of bezelea" 4
- (lambda (user msg)
- (w/get-song
- msg
- (lambda (song)
- (if song
+ w/twitch-redeems
+ (list
+ (list
+ "throw shade" 1
+ (lambda (user shader)
+ (w/write-chat-event (format "%s threw shade" user))
+ (w/db-set "shader" shader)
+ (w/model-record-change)
+ (w/pub '(avatar overlay shader) (list (w/encode-string user) (w/encode-string shader)))))
+ (list
+ "lurker check in" 1
+ (lambda (user _)
+ (w/write-chat-event (format "%s is lurking" user))))
+ (list
+ "mental clarity" 1
+ (lambda (user _)
+ (w/write-chat-event (format "%s established mental clarity" user))
+ (w/stop-all-audio)
+ (w/model-reset)))
+ (list
+ "BOOST" 1
+ (lambda (user _)
+ (unless (-contains? w/twitch-boosters user)
+ (add-to-list 'w/twitch-boosters user)
+ (soundboard//play-clip "yougotboostpower.ogg")
+ (w/write-chat-event (s-concat user " boosted their boost number"))
+ (cl-incf (alist-get :boost w/user-current 0)))))
+ (list
+ "TSOOB" 1
+ (lambda (user _)
+ (unless (-contains? w/twitch-tsoobers user)
+ (add-to-list 'w/twitch-tsoobers user)
+ (soundboard//play-clip "rewoptsoobtoguoy.ogg" 140)
+ (w/write-chat-event (s-reverse (s-concat user " boosted their boost number")))
+ (cl-decf (alist-get :boost w/user-current 0)))))
+ (list
+ "submit headline" 1
+ (lambda (user inp)
+ (w/write-chat-event (format "%s submitted a headline: %s" user inp))
+ (w/glossary-record inp)
+ (w/friend-journalism user inp)))
+ (list
+ "cycle gizmos" 1
+ (lambda (user _)
+ (w/write-chat-event (format "%s cycled the gizmos" user))
+ (w/gizmo-cycle)))
+ (list
+ "allow streamer to drink" 1
+ (lambda (user _)
+ (w/write-chat-event (format "%s allowed the streamer to \"drink\"" user))))
+ (list
+ "deslug" 1
+ (lambda (user _)
+ (w/write-chat-event (format "%s inverted slug" user))))
+ (list
+ "talk to clone" 2
+ (lambda (user inp)
+ (push (cons user inp) w/twitch-chat-history)
+ (let ((w/twitch-chat-history (list (cons user inp)))
+ (w/last-stream-transcription "")
+ (ping (w/message-ping inp)))
+ (w/write-chat-event (s-concat user " asks clone: " inp))
+ (w/fake-chatter-run
+ (w/pick-random
+ (or
+ (and ping (w/dna-user-clones ping))
+ (w/dna-user-clones user)
+ w/fake-chatters))))))
+ (list
+ "spinne" 3
+ (lambda (user _)
+ (w/write-chat-event (s-concat user " activates the spinne cyclle"))
+ (w/model-toggle "spin")))
+ (list
+ "forsen" 3
+ (lambda (user _)
+ (let ((cur (float-time)))
+ (when (> (- cur w/twitch-redeem-sound-last) 2)
+ (w/write-chat-event (s-concat user " loudly exclaims forsenE"))
+ (soundboard//play-clip "cave3.ogg" 75)
+ (w/model-toggle "forsen")
+ (setq w/twitch-redeem-sound-last cur)))))
+ (list
+ "SEASICKNESS GENERATOR" 3
+ (lambda (user _)
+ (w/write-chat-event (s-concat user " is a salty sea dog"))
+ (w/model-toggle "zoom_wave")))
+ (list
+ "The Pharaoh's Curse" 3
+ (lambda (user _)
+ (w/write-chat-event (format "%s drew the ire of the Pharaoh upon me" user))
+ (w/obs-activate-toggle 'pharaohs-curse)
+ ))
+ (list
+ "pursue idol dream" 3
+ (lambda (user _)
+ (w/write-chat-event (format "Helping %s pursue their idol dream~" user))
+ (w/obs-activate-toggle 'chase-dreams)
+ (w/model-region-user-avatar "hair" user)))
+ (list
+ "INTJ stare" 3
+ (lambda (user _)
+ (w/write-chat-event (format "%s suggested a little more sodium chloride next time" user))
+ (w/obs-activate-toggle 'intj-stare)))
+ (list
+ "Live LCOLONQ Reaction" 3
+ (lambda (user _)
+ (w/write-chat-event (format "%s demanded extremely \"hype\" reactions, &c." user))
+ (w/obs-activate-toggle 'live-reaction)))
+ (list
+ "Live friend Reaction" 3
+ (lambda (user _)
+ (w/write-chat-event (format "%s demanded extremely \"hype\" reactions, &c. but from \"friend\"!?" user))
+ (w/obs-activate-toggle 'live-friend-reaction)))
+ (list
+ "bells of bezelea" 4
+ (lambda (user msg)
+ (w/get-song
+ msg
+ (lambda (song)
+ (if song
+ (progn
+ (w/write-chat-event (format "%s played a song: %s (sponsored by Bezelea)" user msg))
+ (w/audio-muzak-enqueue user song))
+ (w/write-chat-event (format "%s played the bells (sponsored by Bezelea)" user))
+ (w/audio-muzak-enqueue user msg))))))
+ (list
+ "activate spell card" 4
+ (lambda (user msg)
+ (w/write-chat-event
+ (format
+ "%s Sign: \"%s\""
+ (s-titleize user)
+ (s-titleized-words (alist-get user w/twitch-chat-history (w/pick-random w/overlay-spellcard-names) nil #'cl-equalp))))
+ (w/overlay-decode-shorthand-bml
+ msg
+ (lambda (data)
+ (w/overlay-start-barrage data)))))
+ (list "palette swap (hair)" 5 (w/handle-redeem-region-swap "hair"))
+ (list "palette swap (highlight)" 5 (w/handle-redeem-region-swap "highlight"))
+ (list "palette swap (eyes)" 5 (w/handle-redeem-region-swap "eyes"))
+ ;; (list "palette swap (hat)" 5 (w/handle-redeem-region-swap "hat"))
+ (list "palette swap (hands)" 5 (w/handle-redeem-region-swap "hands"))
+ (list
+ "run program" 6
+ (lambda (user inp)
+ (if (w/user-authorized)
+ (progn
+ (w/write-chat-event (s-concat user " runs program: " inp))
+ (w/bless inp 50))
+ (w/write-chat-event (format "%s is not authorized to run code" user)))))
+ (list
+ "feed friend" 10
+ (lambda (user inp)
+ (let ((cur (float-time)))
+ (when (> (- cur w/twitch-redeem-sound-last) 2)
+ (w/write-chat-event (s-concat user " feeds \"friend\" " inp))
+ (w/friend-feed user inp)
+ (setq w/twitch-redeem-sound-last cur)))))
+ (list
+ "talk to friend" 10
+ (lambda (user inp)
+ (let ((cur (float-time)))
+ (when (> (- cur w/twitch-redeem-sound-last) 2)
+ (w/write-chat-event (s-concat user " talks to \"friend\": " inp))
+ (w/friend-chat user inp)
+ (setq w/twitch-redeem-sound-last cur)))))
+ (list
+ "friend composes song" 10
+ (lambda (user inp)
+ (let ((cur (float-time)))
+ (when (> (- cur w/twitch-redeem-sound-last) 2)
+ (w/write-chat-event (s-concat user " asks \"friend\" to compose a song about: " inp))
+ (w/friend-compose-song inp)
+ (setq w/twitch-redeem-sound-last cur)))))
+ (list
+ "show friend wikipedia page" 10
+ (lambda (user inp)
+ (let ((cur (float-time)))
+ (when (> (- cur w/twitch-redeem-sound-last) 2)
+ (w/write-chat-event (s-concat user " shows \"friend\" a Wikipedia page: " inp))
+ (w/friend-react-wikipedia user inp)
+ (setq w/twitch-redeem-sound-last cur)))))
+ (list
+ "theme: maris-dark" 50
+ (lambda (user _)
+ (w/write-chat-event (format "%s changed the theme: maris-dark" user))
+ (w/change-theme 'ef-maris-dark)))
+ (list
+ "theme: autumn" 50
+ (lambda (user _)
+ (w/write-chat-event (format "%s changed the theme: autumn" user))
+ (w/change-theme 'ef-autumn)))
+ (list
+ "theme: tritanopia-dark" 50
+ (lambda (user _)
+ (w/write-chat-event (format "%s changed the theme: tritanopia-dark" user))
+ (w/change-theme 'ef-tritanopia-dark)))
+ (list
+ "theme: duo-dark" 50
+ (lambda (user _)
+ (w/write-chat-event (format "%s changed the theme: duo-dark" user))
+ (w/change-theme 'ef-duo-dark)))
+ (list
+ "theme: bio" 50
+ (lambda (user _)
+ (w/write-chat-event (format "%s changed the theme: bio" user))
+ (w/change-theme 'ef-bio)))
+ (list
+ "theme: rosa" 50
+ (lambda (user _)
+ (w/write-chat-event (format "%s changed the theme: rosa" user))
+ (w/change-theme 'ef-rosa)))
+ (list
+ "gamer" 500
+ (lambda (user _)
+ (let ((cur (float-time)))
+ (when (> (- cur w/twitch-redeem-sound-last) 2)
+ (w/write-chat-event (s-concat user "'s Gamer Sacrifice summoned an entity"))
+ (soundboard//play-clip "videogame.ogg")
+ (w/obs-activate-toggle 'thug-life)
+ (setq w/twitch-redeem-sound-last cur)))))
+ (list
+ "arrow" 500
+ (lambda (user msg)
+ (w/write-chat-event (format "%s points and says %S" user msg))
+ (w/obs-activate-toggle 'clickbait msg)))
+ (list
+ "antipiracy" 500
+ (lambda (user _)
+ (w/write-chat-event (format "%s does not condone any form of copyright infringement whatsoever." user))
+ (w/obs-activate-toggle 'activate-nixos)))
+ (list
+ "super idol" 500
+ (lambda (_ _)
+ (let ((cur (float-time)))
+ (when (> (- cur w/twitch-redeem-sound-last) 2)
+ (w/write-chat-event "SuperIdoldexiaorongdoumeinidetianbayuezhengwudeyangguangdoumeiniyaoyanreai105Cdenididiqingchundezhen")
+ (soundboard//play-clip "superidololdshortstyle.ogg")
+ (setq w/twitch-redeem-sound-last cur)))))
+ (list
+ "enable ad block" 500
+ (lambda (user _)
+ (w/write-chat-event (format "%s turned on UltraBlock HYPER: Community Edition" user))
+ (w/banner-ad-block)))
+ (list
+ "hex" 500
+ (lambda (user inp)
+ (let* ((sp (s-split " " inp))
+ (spell (car sp))
+ (target (cadr sp)))
+ (if (and spell target (stringp spell) (stringp target))
(progn
- (w/write-chat-event (format "%s played a song: %s (sponsored by Bezelea)" user msg))
- (muzak/play-tracks song))
- (w/write-chat-event (format "%s played the bells (sponsored by Bezelea)" user))
- (muzak/play-tracks msg))))))
- (list
- "activate spell card" 4
- (lambda (user msg)
- (w/write-chat-event
- (format
- "%s Sign: \"%s\""
- (s-titleize user)
- (s-titleized-words (alist-get user w/twitch-chat-history (w/pick-random w/overlay-spellcard-names) nil #'cl-equalp))))
- (w/overlay-decode-shorthand-bml
- msg
- (lambda (data)
- (w/overlay-start-barrage data)))))
- (list "palette swap (hair)" 5 (w/handle-redeem-region-swap "hair"))
- (list "palette swap (highlight)" 5 (w/handle-redeem-region-swap "highlight"))
- (list "palette swap (eyes)" 5 (w/handle-redeem-region-swap "eyes"))
- ;; (list "palette swap (hat)" 5 (w/handle-redeem-region-swap "hat"))
- (list "palette swap (hands)" 5 (w/handle-redeem-region-swap "hands"))
- (list
- "run program" 6
- (lambda (user inp)
- (if (w/user-authorized)
- (progn
- (w/write-chat-event (s-concat user " runs program: " inp))
- (w/bless inp 50))
- (w/write-chat-event (format "%s is not authorized to run code" user)))))
- (list
- "feed friend" 10
- (lambda (user inp)
- (let ((cur (float-time)))
- (when (> (- cur w/twitch-redeem-sound-last) 2)
- (w/write-chat-event (s-concat user " feeds \"friend\" " inp))
- (w/friend-feed user inp)
- (setq w/twitch-redeem-sound-last cur)))))
- (list
- "talk to friend" 10
- (lambda (user inp)
- (let ((cur (float-time)))
- (when (> (- cur w/twitch-redeem-sound-last) 2)
- (w/write-chat-event (s-concat user " talks to \"friend\": " inp))
- (w/friend-chat user inp)
- (setq w/twitch-redeem-sound-last cur)))))
- (list
- "friend composes song" 10
- (lambda (user inp)
- (let ((cur (float-time)))
- (when (> (- cur w/twitch-redeem-sound-last) 2)
- (w/write-chat-event (s-concat user " asks \"friend\" to compose a song about: " inp))
- (w/friend-compose-song inp)
- (setq w/twitch-redeem-sound-last cur)))))
- (list
- "show friend wikipedia page" 10
- (lambda (user inp)
- (let ((cur (float-time)))
- (when (> (- cur w/twitch-redeem-sound-last) 2)
- (w/write-chat-event (s-concat user " shows \"friend\" a Wikipedia page: " inp))
- (w/friend-react-wikipedia user inp)
- (setq w/twitch-redeem-sound-last cur)))))
- (list
- "theme: maris-dark" 50
- (lambda (user _)
- (w/write-chat-event (format "%s changed the theme: maris-dark" user))
- (w/change-theme 'ef-maris-dark)))
- (list
- "theme: autumn" 50
- (lambda (user _)
- (w/write-chat-event (format "%s changed the theme: autumn" user))
- (w/change-theme 'ef-autumn)))
- (list
- "theme: tritanopia-dark" 50
- (lambda (user _)
- (w/write-chat-event (format "%s changed the theme: tritanopia-dark" user))
- (w/change-theme 'ef-tritanopia-dark)))
- (list
- "theme: duo-dark" 50
- (lambda (user _)
- (w/write-chat-event (format "%s changed the theme: duo-dark" user))
- (w/change-theme 'ef-duo-dark)))
- (list
- "theme: bio" 50
- (lambda (user _)
- (w/write-chat-event (format "%s changed the theme: bio" user))
- (w/change-theme 'ef-bio)))
- (list
- "theme: rosa" 50
- (lambda (user _)
- (w/write-chat-event (format "%s changed the theme: rosa" user))
- (w/change-theme 'ef-rosa)))
- (list
- "gamer" 500
- (lambda (user _)
- (let ((cur (float-time)))
- (when (> (- cur w/twitch-redeem-sound-last) 2)
- (w/write-chat-event (s-concat user "'s Gamer Sacrifice summoned an entity"))
- (soundboard//play-clip "videogame.ogg")
- (w/obs-activate-toggle 'thug-life)
- (setq w/twitch-redeem-sound-last cur)))))
- (list
- "arrow" 500
- (lambda (user msg)
- (w/write-chat-event (format "%s points and says %S" user msg))
- (w/obs-activate-toggle 'clickbait msg)))
- (list
- "antipiracy" 500
- (lambda (user _)
- (w/write-chat-event (format "%s does not condone any form of copyright infringement whatsoever." user))
- (w/obs-activate-toggle 'activate-nixos)))
- (list
- "super idol" 500
- (lambda (_ _)
- (let ((cur (float-time)))
- (when (> (- cur w/twitch-redeem-sound-last) 2)
- (w/write-chat-event "SuperIdoldexiaorongdoumeinidetianbayuezhengwudeyangguangdoumeiniyaoyanreai105Cdenididiqingchundezhen")
- (soundboard//play-clip "superidololdshortstyle.ogg")
- (setq w/twitch-redeem-sound-last cur)))))
- (list
- "hex" 500
- (lambda (user inp)
- (let* ((sp (s-split " " inp))
- (spell (car sp))
- (target (cadr sp)))
- (if (and spell target (stringp spell) (stringp target))
- (progn
- (w/write-chat-event (s-concat user " hexed " target " with: " spell))
- (when-let ((type (alist-get spell w/hex-types nil nil #'s-equals?)))
- (w/hex target user type)))
- (w/write-chat-event (s-concat user "'s hex fizzled out with a puff of smoke!"))))))
- (list
- "VIPPER" 1000
- (lambda (user inp)
- (soundboard//play-clip "aeiou.ogg")
- (w/write-chat-event (s-concat user " gave VIP to " inp))
- (w/twitch-add-vip (s-chop-prefix "@" inp))))
- (list
- "deVIPPER" 1000
- (lambda (user inp)
- (soundboard//play-clip "uoiea.ogg")
- (w/write-chat-event (s-concat user " removed VIP from " inp))
- (w/twitch-remove-vip (s-chop-prefix "@" inp))))
- (list
- "total clarity" 5000
- (lambda (user _)
- (w/stop-all-audio)
- (run-with-timer
- 1 nil
- (lambda () (soundboard//play-clip "gong.ogg")))
- (w/write-chat-event (s-concat user " established total clarity"))
- (w/obs-activate-toggle 'total-clarity)))
- (list
- "canonize me" 20000
- (lambda (user _)
- (w/write-chat-event (s-concat user " was canonized!"))
- (w/bible-canonize user)))
- ))
+ (w/write-chat-event (s-concat user " hexed " target " with: " spell))
+ (when-let ((type (alist-get spell w/hex-types nil nil #'s-equals?)))
+ (w/hex target user type)))
+ (w/write-chat-event (s-concat user "'s hex fizzled out with a puff of smoke!"))))))
+ (list
+ "VIPPER" 1000
+ (lambda (user inp)
+ (soundboard//play-clip "aeiou.ogg")
+ (w/write-chat-event (s-concat user " gave VIP to " inp))
+ (w/twitch-add-vip (s-chop-prefix "@" inp))))
+ (list
+ "deVIPPER" 1000
+ (lambda (user inp)
+ (soundboard//play-clip "uoiea.ogg")
+ (w/write-chat-event (s-concat user " removed VIP from " inp))
+ (w/twitch-remove-vip (s-chop-prefix "@" inp))))
+ (list
+ "spatiotemporal clarity" 2000
+ (lambda (user _)
+ (w/stop-all-audio)
+ (run-with-timer
+ 1 nil
+ (lambda () (soundboard//play-clip "chinesebiblemozartfade.ogg")))
+ (w/write-chat-event (s-concat user " established spatiotemporal clarity"))
+ (w/obs-activate-toggle 'spatiotemporal-clarity)))
+ (list
+ "total clarity" 5000
+ (lambda (user _)
+ (w/stop-all-audio)
+ (run-with-timer
+ 1 nil
+ (lambda () (soundboard//play-clip "gong.ogg")))
+ (w/write-chat-event (s-concat user " established total clarity"))
+ (w/obs-activate-toggle 'total-clarity)))
+ (list
+ "canonize me" 20000
+ (lambda (user _)
+ (w/write-chat-event (s-concat user " was canonized!"))
+ (w/bible-canonize user)))
+ ))
(provide 'wasp-twitch-redeems)
;;; wasp-twitch-redeems.el ends here
diff --git a/src/wasp-twitch.el b/src/wasp-twitch.el
index 0a4039fe..de44c735 100644
--- a/src/wasp-twitch.el
+++ b/src/wasp-twitch.el
@@ -214,7 +214,7 @@ K is called when the download is finished."
(s-concat "/users?login=" user)
(lambda (data)
(let ((url (ht-get (aref (ht-get data "data") 0) "profile_image_url")))
- (w/write-log (format "downloading avatar: %s %s" url path))
+ ;; (w/write-log (format "downloading avatar: %s %s" url path))
(make-process
:name "wasp-download-avatar"
:buffer nil
@@ -536,7 +536,7 @@ CALLBACK will be passed the winner when the poll concludes."
(defun w/twitch-handle-incoming-chat (msg)
"Write MSG to the chat buffer, processing any commands."
- (w/write-log (format "%s" msg))
+ ;; (w/write-log (format "%s" msg))
(let ((user (w/decode-string (car msg))))
(w/user-bind
user
@@ -596,7 +596,7 @@ Optionally, only apply redeems with point costs less than LIMIT."
(defun w/twitch-handle-redeem (r)
"Handle the channel point redeem R."
- (w/write-log r)
+ ;; (w/write-log r)
(let* ((user (car r))
(redeem (cadr r))
(encoded-input (caddr r))
diff --git a/src/wasp-user-whitelist.el b/src/wasp-user-whitelist.el
index 9ff1c392..5205e002 100644
--- a/src/wasp-user-whitelist.el
+++ b/src/wasp-user-whitelist.el
@@ -231,6 +231,12 @@
"szenesis"
"mrteese"
"ranimusv"
+ "remblanc"
+ "katlyranna"
+ "pwfff"
+ "quackthatsmackyo"
+ "thelinuxdeveloper"
+ "hrrawr"
)))
(setq
diff --git a/src/wasp-utils.el b/src/wasp-utils.el
index 31a17996..54cc3cae 100644
--- a/src/wasp-utils.el
+++ b/src/wasp-utils.el
@@ -98,6 +98,10 @@ Optionally append EXT to the path."
"Write DATA to PATH."
(f-write-text data 'utf-8 path))
+(defun w/unix-time ()
+ "Return the current Unix timestamp."
+ (float-time (current-time)))
+
(defun w/daily-log-path ()
"Return the path to today's daily log file."
(format-time-string "~/logs/log-%Y-%m-%d.txt" (current-time)))
@@ -140,7 +144,7 @@ Optionally append EXT to the path."
(defun w/devour (start end)
"Delete and return the region from START to END."
- (w/write-log (format "devouring: %s %s %s" start end (buffer-string)))
+ ;; (w/write-log (format "devouring: %s %s %s" start end (buffer-string)))
(let ((ret (decode-coding-string (buffer-substring start end) 'utf-8)))
(delete-region start end)
ret))