|
|
|
@ -89,7 +89,7 @@ dbot.version : Module to track version and changelog information and update the
|
|
|
|
|
save_state="y"
|
|
|
|
|
date_written="2017-08-12 08:45:15"
|
|
|
|
|
requires="4.98"
|
|
|
|
|
version="2.0032"
|
|
|
|
|
version="2.0033"
|
|
|
|
|
>
|
|
|
|
|
<description trim="y">
|
|
|
|
|
<![CDATA[
|
|
|
|
@ -17686,6 +17686,13 @@ function inv.regen.onSleep(sleepLoc)
|
|
|
|
|
|
|
|
|
|
local retval = DRL_RET_SUCCESS
|
|
|
|
|
|
|
|
|
|
local sleepCmd
|
|
|
|
|
if (sleepLoc == nil) or (sleepLoc == "") then
|
|
|
|
|
sleepCmd = "sleep"
|
|
|
|
|
else
|
|
|
|
|
sleepCmd = "sleep " .. sleepLoc
|
|
|
|
|
end -- if
|
|
|
|
|
|
|
|
|
|
if (inv.config.table.isRegenEnabled) then
|
|
|
|
|
|
|
|
|
|
if (inv.regen.pkg ~= nil) then
|
|
|
|
@ -17693,12 +17700,13 @@ function inv.regen.onSleep(sleepLoc)
|
|
|
|
|
retval = DRL_RET_BUSY
|
|
|
|
|
else
|
|
|
|
|
inv.regen.pkg = {}
|
|
|
|
|
inv.regen.pkg.sleepLoc = sleepLoc
|
|
|
|
|
inv.regen.pkg.sleepCmd = sleepCmd
|
|
|
|
|
wait.make(inv.regen.onSleepCR)
|
|
|
|
|
end -- if
|
|
|
|
|
|
|
|
|
|
else
|
|
|
|
|
check (Send("sleep " .. (sleepLoc or "")))
|
|
|
|
|
dbot.info("FIXME DEBUG: sending sleep command \"" .. sleepCmd .. "\"")
|
|
|
|
|
check (Send(sleepCmd))
|
|
|
|
|
end -- if
|
|
|
|
|
|
|
|
|
|
return retval
|
|
|
|
@ -17712,7 +17720,7 @@ function inv.regen.onSleepCR()
|
|
|
|
|
return DRL_RET_INTERNAL_ERROR
|
|
|
|
|
end -- if
|
|
|
|
|
|
|
|
|
|
local sleepCmd = "sleep " .. inv.regen.pkg.sleepLoc
|
|
|
|
|
local sleepCmd = inv.regen.pkg.sleepCmd
|
|
|
|
|
|
|
|
|
|
-- First look if the user has at least one item providing the regeneration effect. Get an ID array
|
|
|
|
|
-- for all regen items (currently just regen rings have this effect.)
|
|
|
|
|