MA

[Duvida] Spells Com Error

Por matttt00, 25 de set. de 2010 em Archived

otserv
tibia
script
9
1.1k
matttt00M
25 de setembro de 2010 às 11:53

Oi pessoal , sou novo no Xtibia e queria que me ajudassem em uma coisa que esta ocorrendo eh o seguinte :

 

Meu server de DBZ ta tendo uns erros no executavel e o server fica caindo muito rapido :/

 

é assim os erros em umas magias.

 

Lua Script Error: [spell Interface]

In a timer event called from:

data/spells/scripts/renzoku energy dan:onCastSpell

 

e o script da magia eh esse :

 

local combat1 = createCombatObject()

setCombatParam(combat1, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)

setCombatParam(combat1, COMBAT_PARAM_EFFECT, 3)

setCombatParam(combat1, COMBAT_PARAM_DISTANCEEFFECT, 40)

setCombatFormula(combat1, COMBAT_FORMULA_LEVELMAGIC, -4.0, 0, -3.2, 0)

 

local combat2 = createCombatObject()

setCombatParam(combat2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)

setCombatParam(combat2, COMBAT_PARAM_EFFECT, 3)

setCombatParam(combat2, COMBAT_PARAM_DISTANCEEFFECT, 40)

setCombatFormula(combat2, COMBAT_FORMULA_LEVELMAGIC, -4.0, 0, -3.2, 0)

 

 

 

 

 

 

 

local function onCastSpell1(parameters)

doCombat(parameters.cid, parameters.combat1, parameters.var)

end

 

local function onCastSpell2(parameters)

doCombat(parameters.cid, parameters.combat2, parameters.var)

end

 

 

 

 

 

function onCastSpell(cid, var)

local parameters = { cid = cid, var = var, combat1 = combat1, combat2 = combat2, }

addEvent(onCastSpell1, 0, parameters)

addEvent(onCastSpell2, 300, parameters)

 

 

 

 

end

 

porfavor ae pessoal se alguem souber me ajudem ! ;d

 

abraços.

VodkartV
25 de setembro de 2010 às 12:08
local combat1 = createCombatObject()
setCombatParam(combat1, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)
setCombatParam(combat1, COMBAT_PARAM_EFFECT, 3)
setCombatParam(combat1, COMBAT_PARAM_DISTANCEEFFECT, 40)
setCombatFormula(combat1, COMBAT_FORMULA_LEVELMAGIC, -4.0, 0, -3.2, 0)

local combat2 = createCombatObject()
setCombatParam(combat2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)
setCombatParam(combat2, COMBAT_PARAM_EFFECT, 3)
setCombatParam(combat2, COMBAT_PARAM_DISTANCEEFFECT, 40)
setCombatFormula(combat2, COMBAT_FORMULA_LEVELMAGIC, -4.0, 0, -3.2, 0)


local function onCastSpell1(parameters)
doCombat(parameters.cid, parameters.combat1, parameters.var)
end

local function onCastSpell2(parameters)
doCombat(parameters.cid, parameters.combat2, parameters.var)
end


function onCastSpell(cid, var)
local parameters = { cid = cid, var = var, combat1 = combat1, combat2 = combat2}
addEvent(onCastSpell1, 100, parameters)
addEvent(onCastSpell2, 300, parameters)
return TRUE
end

matttt00M
25 de setembro de 2010 às 12:37

Vodkart coloquei esse script que vc mandou e a spell ficou sem exhausted :/ alguma sugestão?

VodkartV
25 de setembro de 2010 às 13:49

qual tag vc ta usando no spells.xml?

matttt00M
25 de setembro de 2010 às 13:55

esse : <instant name="Renzoku Energy Dan" words="renzoku energy dan" needtarget="1" direction="1" lvl="5" maglv="10" mana="1000" soul="0" exhaustion="1" prem="0" enabled="1" script="renzoku energy dan.lua"></instant>

VodkartV
25 de setembro de 2010 às 14:02

tem que mudar essa parte:

 

exhaustion="1"

 

se vc quiser 5 segundos seria assim:

 

ex

haustion="5000" 

 

ou sejá

 

1000 = 1 segundos

 

flw

matttt00M
25 de setembro de 2010 às 14:13

coloquei 1000 e mesmo assim ficou sem exhausted :/

VodkartV
25 de setembro de 2010 às 14:28

tenta assim:

 

<instant name="Renzoku Energy Dan" words="renzoku energy dan" selftarget="1" aggressive="0" lvl="5" maglv="10" mana="1000" soul="0" exhaustion="2000" prem="1" enabled="1" script="renzoku energy dan.lua">
<vocation id="1"/>
<vocation id="2"/>
<vocation id="3"/>
<vocation id="4"/>
<vocation id="5"/>
<vocation id="6"/>
<vocation id="7"/>
<vocation id="8"/>
</instant>

 

 

aqui deu exausted :X

vamosnessaV
25 de setembro de 2010 às 15:25

vodkart, olha meu topico pf? to em duvida sobre spell de ot 8.54 pra nova vocation

http://www.xtibia.com/forum/topic/141362-nova-vocationcom-spell/

 

obrigado,

 

aguardando..