• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

some can fix this manarune?

Stewie

Family Guy # ;3
Joined
May 3, 2010
Messages
786
Reaction score
12
Location
TV
Hava This error:

Code:
[04/07/2010 10:16:49] [Error - Spell Interface] 
[04/07/2010 10:16:49] data/spells/scripts/manarune.lua:onCastSpell
[04/07/2010 10:16:49] Description: 
[04/07/2010 10:16:49] (luaDoTargetCombatCondition) Condition not found

here script:

Code:
-- >>CONFIGURAÇÃO<< --Lucasdel12 otserv.com.br--
local MIN_MANA_GAIN = 300 -- Não mecha, pois esta balançeada com a UH
local MIN_MANA_RAND = 350 -- Não mecha, pois esta balançeada com a UH
local MAX_MANA_RAND = 450 -- Não mecha, pois esta balançeada com a UH
local ACCEPT_LUCK = true -- Aqui você escolhe se o player pode ter uma sorte de almentar um pouco mais,TRUE para sim, FALSE para não
local MAG_LEVEL_MULTI = 1 -- Não mecha, pois esta balançeada com a UH
local LEVEL_MULTI = 1 -- Não mecha, pois esta balançeada com a UH
local MAGIC_EFFECT = CONST_ME_BATS -- O Efeito quando usa a runa.
local ANIMATION_COLOR = 37 -- Não mecha nisso
local HEAL_TIMES = 1 -- Não mecha nisso
local FIRST_HEAL_DELAY = 0 -- Não mecha nisso
local HEAL_DELAY = 1000 -- Aqui é o exhaust,Ta 1 seg

local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_TARGETCASTERORTOPMOST, 1)
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0)
local exhaust = createConditionObject(CONDITION_EXHAUSTED)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, HEAL_TIMES * HEAL_DELAY + FIRST_HEAL_DELAY)

function onCastSpell(cid, var)
doTargetCombatCondition(0, cid, exhaust, CONST_ME_NONE)
local function doHealMana(parameters)
local random = math.random(MIN_MANA_RAND, MAX_MANA_RAND)
if ACCEPT_LUCK == true then
local luck = math.random(1, 100)
if luck >= 90 then
random = random * 2
elseif luck == 50 then
random = random * 3
end
end
local formula = (getPlayerLevel(cid) * LEVEL_MULTI) + (getPlayerMagLevel(cid) * MAG_LEVEL_MULTI) + random
local manaGain = math.max(MIN_MANA_GAIN, formula)
doPlayerAddMana(cid, manaGain)
doCreatureSay(cid,"otserv.com.br!",19)
doSendAnimatedText(getPlayerPosition(cid), manaGain, ANIMATION_COLOR)
doSendMagicEffect(getPlayerPosition(cid), MAGIC_EFFECT)
doCombat(parameters.cid, parameters.combat, parameters.var)
end
local times = HEAL_TIMES
local parameters = {cid = cid, combat = combat, var = var}
while times > 0 do
if times == HEAL_TIMES then
addEvent(doHealMana, FIRST_HEAL_DELAY, parameters)
else
addEvent(doHealMana, HEAL_DELAY * times, parameters) 
end
times = times - 1
end
end
 
Back
Top