diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2019-01-30 21:18:41 +0000 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2019-01-30 22:22:23 +0000 |
commit | 7efd85325351dc14a60206eef3cd48f0cd6ca622 (patch) | |
tree | bc5ed82d86347b8b3f645a9d1d6271af7fefcc8a /scripts/toy.groovy | |
parent | Add randRange helper (diff) | |
download | toy-7efd85325351dc14a60206eef3cd48f0cd6ca622.zip |
Load the DOMME object
Diffstat (limited to 'scripts/toy.groovy')
-rw-r--r-- | scripts/toy.groovy | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/scripts/toy.groovy b/scripts/toy.groovy index 70848fc..42b78f1 100644 --- a/scripts/toy.groovy +++ b/scripts/toy.groovy @@ -36,6 +36,7 @@ final FRIENDS = [ "Tori", "Sophie", "Krystal" ]; // toy.position final KNEELING = "kneeling", ALLFOURS = "allfours", STANDING = "standing"; def OWNER = null; +def DOMME = null; final SITTER = "sarah-james"; final SOFT = "soft"; @@ -1617,6 +1618,7 @@ def setupShowCalendar = { // GO! setDefault("toy.owner", "ancilla"); OWNER = loadString("toy.owner"); +DOMME = Eval.me(new File("$DATAFOLDER/images/toy/$OWNER/domme.groovy").text); def getDayNum = { Math.floorDiv(getTime() + localTimeOffset() - 14400, 86400) }; def getAvail = { dayNum -> loadInteger("toy.availability.$dayNum") ?: 0 }; def addAvail = { amount -> @@ -1690,7 +1692,7 @@ while (true) { opts.push([ lbl: "May I be un-$it".toString(), act: requestRelease, arg: it ]); }; opts.push([ lbl: "Back", act: null ]); - def opt = getSelectedValue("Yes, toy?", opts.collect { it.lbl }); + def opt = getSelectedValue(is("DEBUG") ? DOMME : "Yes, toy?", opts.collect { it.lbl }); def act = opts[opt].act; if (act) act(opts[opt].arg); @@ -1775,6 +1777,7 @@ while (true) { * images/toy/ancilla/pink/9.jpg * images/toy/ancilla/pink/tags * images/toy/ancilla/lounge.jpg + * images/toy/ancilla/domme.groovy * sounds/toy/165bpm.mp3 * sounds/toy/180bpm.mp3 * sounds/toy/240bpm.mp3 |