summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2018-12-09 21:03:34 +0000
committerDan Goodliffe <dan@randomdan.homeip.net>2018-12-09 21:03:34 +0000
commitac2b5f3da3487e40460c20a342f15ef66e34cf79 (patch)
tree470e23b9aa1cdbd2af1e69826902ef8da42d43f5 /scripts
parentRemove strip/spin.. never liked it (diff)
downloadtoy-ac2b5f3da3487e40460c20a342f15ef66e34cf79.zip
Fix permit cum and add event
Diffstat (limited to 'scripts')
-rw-r--r--scripts/toy.groovy11
1 files changed, 6 insertions, 5 deletions
diff --git a/scripts/toy.groovy b/scripts/toy.groovy
index f8806d9..fd12703 100644
--- a/scripts/toy.groovy
+++ b/scripts/toy.groovy
@@ -20,6 +20,7 @@ final BALLGAG = "ballgag", COLLAR = "dog_collar", CLAMPS = "nipple_clamps", CHAS
final BONDAGE = "bondage", CBT = "cbt", CHORES = "chores", PAIN = "pain";
// toy.permission.<name>
final CUM = "cum", EDGE = "edge"
+final PERMIT = "permit";
// toy.state.<name>
final CHASTE = "chaste", COLLARED = "collared", CUFFED = "cuffed", CLAMPED = "clamped", GAGGED = "gagged", NAKED = "naked";
// toy.plan.<name>.{start|end|friend} UTC times
@@ -163,17 +164,17 @@ def nextEvent = { events ->
return first;
};
def setEvent = { events, name, time, func, arg = null ->
- if (namedEvents.containsKey(name)) {
+ if (namedEvents.containsKey(func)) {
events[name] = [
time: time,
func: func,
arg: arg
];
- return true;
saveEvents(events);
+ return true;
}
else {
- showPopup("No such event $name");
+ showPopup("No such event $func");
return false;
}
};
@@ -938,7 +939,7 @@ def sessionPlay = {
playRepeat(1 + getRandom(3), [playStrokes, playEdges]);
playTake(getRandom(3), [postCum, postChastity]);
if (!sessionAborted) {
- addEventIfMissing(CUM, getTime() + (DAY * 2) + getRandom(DAY * 2), "givePermission", CUM); // 2 - 4 days from now
+ addEventIfMissing(CUM, getTime() + (DAY * 2) + getRandom(DAY * 2), PERMIT, CUM); // 2 - 4 days from now
}
}
};
@@ -1155,7 +1156,7 @@ def beginPlan = { plan ->
// Initial - basic checks and defaults
namedEvents = [
// name: func(arg, schedTime rt)
- "givePermission": { arg, schedTime, rt -> givePermission(arg) }
+ permit: { arg, schedTime, rt -> givePermission(arg) }
];
def setupInitial = {
if (loadInteger("toy.version") == null) {