Entranced
I'm not Jesus
I've tried many different combinations of using the exura script inside the great mana potion action script, and it wont work.
I'm trying to create potions that "heal" higher as your level gets higher, like a healing spell works. The higher you level, the more it fills.
I've searched many different places, and have yet to find a formula/script.
Here was my script for strong mana potion, it didn't show any errors when I ran the server, but when I logged on, I wasn't able to use potions.
The server I'm running is the newest TFS crying dampson
I'm trying to create potions that "heal" higher as your level gets higher, like a healing spell works. The higher you level, the more it fills.
I've searched many different places, and have yet to find a formula/script.
Here was my script for strong mana potion, it didn't show any errors when I ran the server, but when I logged on, I wasn't able to use potions.
The server I'm running is the newest TFS crying dampson
Code:
function onGetFormulaValues(cid, level, maglevel)
local MIN = (level * 1 + maglevel * 4) * .4
local MAX = (level * 1 + maglevel * 4) * .6
local EMPTY_POTION = 7634
if min < 20 then
min = 20
end
return min, max
end
local exhaust = createConditionObject(CONDITION_EXHAUST)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, (getConfigInfo('timeBetweenExActions') - 100))
function onUse(cid, item, fromPosition, itemEx, toPosition)
if isPlayer(itemEx.uid) == FALSE then
return FALSE
end
if hasCondition(cid, CONDITION_EXHAUST_HEAL) == TRUE then
doPlayerSendDefaultCancel(cid, RETURNVALUE_YOUAREEXHAUSTED)
return TRUE
end
if doPlayerAddMana(itemEx.uid, math.random(MIN, MAX)) == LUA_ERROR then
return FALSE
end
doAddCondition(cid, exhaust)
doSendMagicEffect(getThingPos(itemEx.uid), CONST_ME_MAGIC_BLUE)
doCreatureSay(itemEx.uid, "Aaaah...", TALKTYPE_ORANGE_1)
return TRUE
end
Last edited: