From c92f41c9edb8546da266923b22182346d9526e75 Mon Sep 17 00:00:00 2001 From: tilpner Date: Sun, 12 Aug 2018 21:17:04 +0200 Subject: Add (power) and (user-get) commands --- modules/3-store.rkt | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 modules/3-store.rkt (limited to 'modules') diff --git a/modules/3-store.rkt b/modules/3-store.rkt new file mode 100644 index 0000000..aa44169 --- /dev/null +++ b/modules/3-store.rkt @@ -0,0 +1,11 @@ +#lang racket/base +(require irc/bot irc/command irc/storage irc/users + racket/format) + +(define-command (power) + #:help "Displays your registered power level" + (reply (~a (user-power (source))))) + +(define-command (user-get path) + #:power 2 + (reply (~s (apply ref (user-storage (source)) path)))) -- cgit v1.2.3