summaryrefslogtreecommitdiffstats
path: root/nfsw
diff options
context:
space:
mode:
authorrsiddharth <s@ricketyspace.net>2019-10-19 14:17:38 -0400
committerrsiddharth <s@ricketyspace.net>2019-10-19 14:17:38 -0400
commit26031fdfd60b3b6e84dd9fb1f5f44dc299bbb500 (patch)
treeebab760f1cf905a066125efd3a8ec87d7aa7949f /nfsw
parentc0bcd751c263d1267da41af03bfdaa081e8abb21 (diff)
nfsw/scenes.py: Updat strayed.
Flesh it out.
Diffstat (limited to 'nfsw')
-rw-r--r--nfsw/scenes.py70
1 files changed, 69 insertions, 1 deletions
diff --git a/nfsw/scenes.py b/nfsw/scenes.py
index 9996e1d..5e67a9a 100644
--- a/nfsw/scenes.py
+++ b/nfsw/scenes.py
@@ -415,4 +415,72 @@ def coitus(o):
def strayed(o):
- return 'Code Strayed'
+ r = redis()
+
+ gobbledygook = [
+ 'You know one of Sugar\'s books was'
+ '\nselected for Oprah\'s Book Club 2.0.',
+ 'Also the book was adapted into a'
+ '\nbiographical drama film.',
+ 'Ok, this is the last one.'
+ '\nChuck Palahniuk mentions about Sugar'
+ '\nin Joe Rogan\'s podcast.'
+ ]
+
+ def rj(name):
+ return read_junk('strayed/{}'.format(name))
+
+
+ def gg():
+ l = len(gobbledygook)
+
+ for i in range(0, l):
+ if r.sismember('scene:strayed:gg', i):
+ continue
+
+ r.sadd('scene:strayed:gg', i)
+ return gobbledygook[i]
+
+ return rj('passed-out')
+
+
+ def p_done():
+ # Mark scene done
+ r.sadd('scenes:done', 'strayed')
+
+ # Move to next scene
+ r.set('scene', 'xkcd')
+
+ return '\n\n'.join([
+ rj('into-white'),
+ xkcd({'intro': 1})
+ ])
+
+
+ def p(q):
+ if 'fuck' in q:
+ return rj('fuck')
+
+ if 'masturbate' in q:
+ return rj('masturbate')
+
+ if 'cheryl strayed' in q:
+ return p_done()
+
+ return gg()
+
+
+ if 'intro' in o:
+ return rj('intro')
+
+
+ if 'q' in o:
+ return p(o['q'])
+
+
+def xkcd(o):
+ return 'XKCD Sky'
+
+
+def bedroom(o):
+ return 'You are in your bedroom'