Try this
local exhaust = createConditionObject(CONDITION_EXHAUST)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, (getConfigInfo('timeBetweenExActions') - 1000))
function onUse(cid, item, fromPosition, itemEx, toPosition)
local mana_min = (getCreatureMaxMana(cid) / 100) * 9
local...