Erro Spell

kadevidaloka
em Lixeira Pública

kadevidaloka

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 30/06/09Posts: 51Char no Tibia: Assassin of Shadow

queria saber aonde ta o erro nessa spell e queria saber se alguem pode me repassar ela certinho sem bug!

 

 

local combat = createCombatObject()

setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)

setCombatParam(combat, COMBAT_PARAM_EFFECT, 4)

setCombatFormula(combat, COMBAT_FORMULA_LEVELMAGIC, -2.2, -150, -2.5, 1)

 

 

arr = {

{0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0},

{0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0},

{0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0},

{0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0},

{0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0},

{1, 1, 1, 1, 1, 3, 1, 1, 1, 1, 1},

{0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0},

{0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0},

{0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0},

{0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0},

{0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0},

}

 

 

local area = createCombatArea(arr)

setCombatArea(combat, area)

 

function onCastSpell(cid, var)

return doCombat(cid, combat, var)

end

 

position = getCreaturePosition(cid)

hitpos = {x = position.x - math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x - math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x - math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x - math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

 

hitpos = {x = position.x - math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x - math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x - math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x - math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

 

hitpos = {x = position.x + math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x + math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x + math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x + math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

 

hitpos = {x = position.x + math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x + math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x + math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x + math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

 

 

 

end

zase35

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 13/10/08Posts: 11Char no Tibia: Kazuya

Qual A versao 8.50 ou 8.40?

kadevidaloka

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 30/06/09Posts: 51Char no Tibia: Assassin of Shadow

8.50

 

^^

satan666

Antichrist Superstar
avatar
Conde
Conde

INFOS

Grupo: CondeRegistrado: 07/05/08Posts: 612Char no Tibia: leviana luciferiana

a meu ver o que esta errado e o END no final do script que nao esta fechando nada.

 

e a função ja foi fechada antes então tudos que estiver abaixo dela nao sera executada.

creationb.jpg

"Um Deus que usasse seu poder para criar seres humanos que de antemão sabia que seriam atormentados eternamente, e que os predestinasse a isso,



não poderia ser sábio, nem justo e tampouco amoroso.

Além de nos submeter a isso vim a nos julgar e condenar por nossos atos aos tormentos do inferno.

pra minha pessoa isso não é um Deus Pai amoroso e bondoso como o chaman, seu padrão seria muito mais inferior do que o de muitos homens."

kadevidaloka

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 30/06/09Posts: 51Char no Tibia: Assassin of Shadow

queria que vc arrumasse essa aki pra funcionar tambem \/

 

local area = createCombatArea(AREA_SQUARE1X1)

function onCastSpell(cid, var)

local target = getCreatureTarget(cid)

doSendDistanceShoot(getCreaturePosition(cid),{x = getCreaturePosition(cid).x - math.random(4,6), y = getCreaturePosition(cid).y - 5, z = getCreaturePosition(cid).z},CONST_ANI_FLAMMINGARROW)

for x = 1, 10 do

addEvent(furyAttackTarget,200*x+500,cid,target,{x = getCreaturePosition(target).x + math.random(-1,1), y = getCreaturePosition(target).y + math.random(-1,1), z = getCreaturePosition(target).z})

end

end

function furyAttackTarget(cid,target,pos)

if isCreature(cid) == TRUE and isCreature(target) == TRUE then

doSendDistanceShoot({x = getCreaturePosition(target).x - math.random(4,6), y = getCreaturePosition(target).y - 5, z = getCreaturePosition(target).z},pos,CONST_ANI_FIRE)

doAreaCombatHealth(cid,COMBAT_FIREDAMAGE,pos,area,(-(getPlayerLevel(cid)*getPlayerMagLevel(cid))/5)+50,(-(getPlayerLevel(cid)*getPlayerMagLevel(cid))/5)-50,CONST_ME_HITBYFIRE)

end

end

 

 

ela da o recente bug do nao gasta mana nem da exaust ela e magia target entao acho que e facil arrumar!

 

marcyzius ainda nao pegou a spell velho!

kadevidaloka

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 30/06/09Posts: 51Char no Tibia: Assassin of Shadow

bug do end resolvido mais mesmo assim a spell continua com o poblema de nao gastar mana nem dar exausted ja configurei ela pra funcionar na versao 8.42+ soq mesmo assim continua dando esse bug!

 

to precisando de 1 help urgente!

 

ta ai a script da spell alguem consegue ver aonde esta o bug?

 

local combat = createCombatObject()

setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)

setCombatParam(combat, COMBAT_PARAM_EFFECT, 4)

 

function getCombatFormulas(cid, lv, maglv)

local formula_min = -((lv*0.25 + maglv*3) * 5.6)

local formula_max = -((lv*0.25 + maglv*3) * 6.0)

 

if(formula_max < formula_min) then

local tmp = formula_max

formula_max = formula_min

formula_min = tmp

end

return formula_min, formula_max

end

 

local area = createCombatArea(AREA_METEOR1)

setCombatArea(combat, area)

 

setCombatCallback(combat, CALLBACK_PARAM_LEVELMAGICVALUE, "getCombatFormulas")

 

function onCastSpell(param)

doCombat(param.cid, param.combat, param.var)

end

local combat2 = createCombatObject()

setCombatParam(combat2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)

setCombatParam(combat2, COMBAT_PARAM_EFFECT, 4)

 

function getCombatFormulas(cid, lv, maglv)

local formula_min = -((lv*0.25 + maglv*3) * 5.6)

local formula_max = -((lv*0.25 + maglv*3) * 6.0)

 

if(formula_max < formula_min) then

local tmp = formula_max

formula_max = formula_min

formula_min = tmp

end

return formula_min, formula_max

end

 

local area2 = createCombatArea(AREA_METEOR1)

setCombatArea(combat2, area2)

 

function onCastSpell(param)

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

end

setCombatCallback(combat2, CALLBACK_PARAM_LEVELMAGICVALUE, "getCombatFormulas")

 

function onCastSpell(cid, var)

local param = {cid=cid, combat2=combat2, var=var}

addEvent(onCastSpell2, 200, param)

 

position = getCreaturePosition(cid)

hitpos = {x = position.x - math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x - math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x - math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x - math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

 

hitpos = {x = position.x - math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x - math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x - math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x - math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x + math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

 

hitpos = {x = position.x + math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x + math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x + math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x + math.random(1, 7), y = position.y + math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y - math.random(1, 3), z = position.z}, 3)

 

 

hitpos = {x = position.x + math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x + math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x + math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

hitpos = {x = position.x + math.random(1, 7), y = position.y - math.random(1, 7), z = position.z}

doSendDistanceShoot(hitpos, {x = position.x - math.random(1, 3), y = position.y + math.random(1, 3), z = position.z}, 3)

 

 

 

 

end