summaryrefslogtreecommitdiff
path: root/src/wasp-overlay.el
diff options
context:
space:
mode:
Diffstat (limited to 'src/wasp-overlay.el')
-rw-r--r--src/wasp-overlay.el9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/wasp-overlay.el b/src/wasp-overlay.el
index c4e63e3b..e902eb3d 100644
--- a/src/wasp-overlay.el
+++ b/src/wasp-overlay.el
@@ -45,5 +45,14 @@
(w/get-heartrate)
)))
+(defun w/overlay-automata (user s &optional color)
+ "Send a cellular automata S from USER in RLE format to the overlay.
+Optionally, make the cells be COLOR."
+ (w/pub '(avatar automata spawn)
+ (list
+ (w/encode-string s)
+ (w/encode-string user)
+ (w/encode-string (or color (w/random-color))))))
+
(provide 'wasp-overlay)
;;; wasp-overlay.el ends here