From 8f38ff3fb33ac377974c70573cef3fb8f5d4a88f Mon Sep 17 00:00:00 2001 From: Kaan Soral Date: Sun, 18 Dec 2016 03:02:50 +0300 Subject: [PATCH] Added activate and shift functions --- runner_functions.js | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/runner_functions.js b/runner_functions.js index 55bda16..6b71773 100644 --- a/runner_functions.js +++ b/runner_functions.js @@ -3,6 +3,19 @@ var character=parent.character; var G=parent.G; // Game data var safeties=true; +function activate(num) // activates an item, likely a booster, in the num-th inventory slot +{ + parent.activate(num); +} + +function shift(num,name) // shifts an item, likely a booster, in the num-th inventory slot +{ + // shift(0,'xpbooster') + // shift(0,'luckbooster') + // shift(0,'goldbooster') + parent.shift(num,name); +} + function item_properties(item) // example: item_properties(character.items[0]) { if(!item || !item.name) return {}; @@ -24,7 +37,6 @@ function item_value(item) // example: item_value(character.items[0]) return calculate_item_value(item); } - function get_socket() { return parent.socket;