b-movie operation name generator

This commit is contained in:
Christine Dodrill 2015-11-10 21:00:09 -08:00
parent 1b606447be
commit 4822009cb9
3 changed files with 3829 additions and 0 deletions

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

26
plugins/opname.py Normal file
View File

@ -0,0 +1,26 @@
from random import choice
from random import randint
from util import hook
prefix = []
suffix = []
#Read prefix and suffix lines in
with open("./plugins/data/opname_prefix.txt", 'r') as prefixfile:
prefix = prefixfile.readlines()
with open("./plugins/data/opname_suffix.txt", 'r') as suffixfile:
suffix = suffixfile.readlines()
#Strip lines and prune junk lines
for ix in [prefix, suffix]:
for junk in range(len(ix)-1, -1, -1):
ix[junk] = ix[junk].strip()
@hook.command
def opname(inp):
#Create phrase
phrase = "OPERATION %s %s %s" % \
(choice(prefix), choice(prefix), choice(suffix))
return phrase.upper()