Ir para conteúdo
  • Cadastre-se

(Resolvido)[AJUDA]Erro no Effect da spell


Ir para solução Resolvido por Ken Kaneki,

Posts Recomendados

Galera eu peguei uma spell de outro OT e o effect também mas quando eu vou usar a spell da um erro no Forgotten Server.

 

E não aparece o effect da spell mas fala que eu estou com o buff.

 

A script é essa:

 

local tempo = 180 -- tempo em segundos.

     
local ml = 15 -- quantos ira aumentar o skill de ML
local skillfist = 0 -- quantos ira aumentar o skill de Fist
local skillsword = 0 -- quantos ira aumentar o skill de Sword
local skillaxe = 0 -- quantos ira aumentar o skill de Axe
local skillclub = 15 -- quantos ira aumentar o skill de Club
local skilldistance = 0 -- quantos ira aumentar o skill de Distance
local skillshield = 0 -- quantos ira aumentar o skill de Shield
local health = 25 -- A cada 1 segundo quantos aumentar de vida
local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0)
     
local condition = createConditionObject(CONDITION_ATTRIBUTES)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_STAT_MAGICLEVEL, ml)
setConditionParam(condition, CONDITION_PARAM_SKILL_FIST, skillfist)
setConditionParam(condition, CONDITION_PARAM_SKILL_SWORD, skillsword)
setConditionParam(condition, CONDITION_PARAM_SKILL_AXE, skillaxe)
setConditionParam(condition, CONDITION_PARAM_SKILL_CLUB, skillclub)
setConditionParam(condition, CONDITION_PARAM_SKILL_DISTANCE, skilldistance)
setConditionParam(condition, CONDITION_PARAM_SKILL_SHIELD, skillshield)
setConditionParam(condition, CONDITION_PARAM_OUTFIT, outfit)
setCombatCondition(combat, condition)
     
local condition = createConditionObject(CONDITION_HASTE)
setConditionParam(condition, CONDITION_PARAM_SPEED, 300)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)
setCombatCondition(combat, condition)
     
local condition = createConditionObject(CONDITION_REGENERATION)
setConditionParam(condition, CONDITION_PARAM_SUBID, 1)
setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_HEALTHGAIN, health)
setConditionParam(condition, CONDITION_PARAM_HEALTHTICKS, 1000)
setCombatCondition(combat, condition)
                  
function onCastSpell(cid, var)
if getPlayerStorageValue(cid, 102053) ~= 1 or getCreatureCondition(cid, CONDITION_REGENERATION, 1) == false then
    doCombat(cid, combat, var)
    setPlayerStorageValue(cid, 102053,1)
repeatEff(cid, 290, 120)
    doCreatureSay(cid, "Bijuu Chakra Mode", TALKTYPE_MONSTER)
else
    doPlayerSendCancel(cid, "Sorry, you are transformed.")
end

end

 

 

Ficarei grato se alguem me ajudar..

post-78172-0-16298900-1418226437_thumb.p

post-78172-0-97069600-1418226440_thumb.p

                                                       

 

 

                                                                                           5e1fc80227b414e178a2f7de00379363.jpg.fb527fa5863cba1c20b81b6ea6841da0.jpg                                                                                                  

Link para o post
Compartilhar em outros sites

tente assim só para teste:

 

 

local tempo = 180 -- tempo em segundos.

 

     
local ml = 15 -- quantos ira aumentar o skill de ML
local skillfist = 0 -- quantos ira aumentar o skill de Fist
local skillsword = 0 -- quantos ira aumentar o skill de Sword
local skillaxe = 0 -- quantos ira aumentar o skill de Axe
local skillclub = 15 -- quantos ira aumentar o skill de Club
local skilldistance = 0 -- quantos ira aumentar o skill de Distance
local skillshield = 0 -- quantos ira aumentar o skill de Shield
local health = 25 -- A cada 1 segundo quantos aumentar de vida
local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0)
     
local condition = createConditionObject(CONDITION_ATTRIBUTES)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_STAT_MAGICLEVEL, ml)
setConditionParam(condition, CONDITION_PARAM_SKILL_FIST, skillfist)
setConditionParam(condition, CONDITION_PARAM_SKILL_SWORD, skillsword)
setConditionParam(condition, CONDITION_PARAM_SKILL_AXE, skillaxe)
setConditionParam(condition, CONDITION_PARAM_SKILL_CLUB, skillclub)
setConditionParam(condition, CONDITION_PARAM_SKILL_DISTANCE, skilldistance)
setConditionParam(condition, CONDITION_PARAM_SKILL_SHIELD, skillshield)
setConditionParam(condition, CONDITION_PARAM_OUTFIT, outfit)
setCombatCondition(combat, condition)
     
local condition = createConditionObject(CONDITION_HASTE)
setConditionParam(condition, CONDITION_PARAM_SPEED, 300)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)
setCombatCondition(combat, condition)
     
local condition = createConditionObject(CONDITION_REGENERATION)
setConditionParam(condition, CONDITION_PARAM_SUBID, 1)
setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_HEALTHGAIN, health)
setConditionParam(condition, CONDITION_PARAM_HEALTHTICKS, 1000)
setCombatCondition(combat, condition)
                  
function onCastSpell(cid, var)
if getPlayerStorageValue(cid, 102053) ~= 1 or getCreatureCondition(cid, CONDITION_REGENERATION, 1) == false then
    doCombat(cid, combat, var)
    setPlayerStorageValue(cid, 102053,1)
repeatEff(cid, 120, 140)
    doCreatureSay(cid, "Bijuu Chakra Mode", TALKTYPE_MONSTER)
else
    doPlayerSendCancel(cid, "Sorry, you are transformed.")
end

end

Editado por Dieguiin XP (veja o histórico de edições)

Att,
Dieguiin XP

 

»»http://baiakfull.com/««

Link para o post
Compartilhar em outros sites

Não amigo fico a mesma coisa.

                                                       

 

 

                                                                                           5e1fc80227b414e178a2f7de00379363.jpg.fb527fa5863cba1c20b81b6ea6841da0.jpg                                                                                                  

Link para o post
Compartilhar em outros sites

Tente assim:

local tempo = 180 -- tempo em segundos.


local ml = 15 -- quantos ira aumentar o skill de ML
local skillfist = 0 -- quantos ira aumentar o skill de Fist
local skillsword = 0 -- quantos ira aumentar o skill de Sword
local skillaxe = 0 -- quantos ira aumentar o skill de Axe
local skillclub = 15 -- quantos ira aumentar o skill de Club
local skilldistance = 0 -- quantos ira aumentar o skill de Distance
local skillshield = 0 -- quantos ira aumentar o skill de Shield
local health = 25 -- A cada 1 segundo quantos aumentar de vida
local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0)

local condition = createConditionObject(CONDITION_ATTRIBUTES)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_STAT_MAGICLEVEL, ml)
setConditionParam(condition, CONDITION_PARAM_SKILL_FIST, skillfist)
setConditionParam(condition, CONDITION_PARAM_SKILL_SWORD, skillsword)
setConditionParam(condition, CONDITION_PARAM_SKILL_AXE, skillaxe)
setConditionParam(condition, CONDITION_PARAM_SKILL_CLUB, skillclub)
setConditionParam(condition, CONDITION_PARAM_SKILL_DISTANCE, skilldistance)
setConditionParam(condition, CONDITION_PARAM_SKILL_SHIELD, skillshield)
setConditionParam(condition, CONDITION_PARAM_OUTFIT, outfit)
setCombatCondition(combat, condition)

local condition = createConditionObject(CONDITION_HASTE)
setConditionParam(condition, CONDITION_PARAM_SPEED, 300)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)
setCombatCondition(combat, condition)

local condition = createConditionObject(CONDITION_REGENERATION)
setConditionParam(condition, CONDITION_PARAM_SUBID, 1)
setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_HEALTHGAIN, health)
setConditionParam(condition, CONDITION_PARAM_HEALTHTICKS, 1000)
setCombatCondition(combat, condition)

function onCastSpell(cid, var)
if getPlayerStorageValue(cid, 102053) ~= 1 or getCreatureCondition(cid, CONDITION_REGENERATION, 1) == false then
doCombat(cid, combat, var)
setPlayerStorageValue(cid, 102053,1)
doCreatureSay(cid, "Bijuu Chakra Mode", TALKTYPE_MONSTER)
else
doPlayerSendCancel(cid, "Sorry, you are transformed.")
end
end

Att,
Dieguiin XP

 

»»http://baiakfull.com/««

Link para o post
Compartilhar em outros sites

Tente assim:

local tempo = 180 -- tempo em segundos.

local ml = 15 -- quantos ira aumentar o skill de ML

local skillfist = 0 -- quantos ira aumentar o skill de Fist

local skillsword = 0 -- quantos ira aumentar o skill de Sword

local skillaxe = 0 -- quantos ira aumentar o skill de Axe

local skillclub = 15 -- quantos ira aumentar o skill de Club

local skilldistance = 0 -- quantos ira aumentar o skill de Distance

local skillshield = 0 -- quantos ira aumentar o skill de Shield

local health = 25 -- A cada 1 segundo quantos aumentar de vida

local combat = createCombatObject()

setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0)

local condition = createConditionObject(CONDITION_ATTRIBUTES)

setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)

setConditionParam(condition, CONDITION_PARAM_STAT_MAGICLEVEL, ml)

setConditionParam(condition, CONDITION_PARAM_SKILL_FIST, skillfist)

setConditionParam(condition, CONDITION_PARAM_SKILL_SWORD, skillsword)

setConditionParam(condition, CONDITION_PARAM_SKILL_AXE, skillaxe)

setConditionParam(condition, CONDITION_PARAM_SKILL_CLUB, skillclub)

setConditionParam(condition, CONDITION_PARAM_SKILL_DISTANCE, skilldistance)

setConditionParam(condition, CONDITION_PARAM_SKILL_SHIELD, skillshield)

setConditionParam(condition, CONDITION_PARAM_OUTFIT, outfit)

setCombatCondition(combat, condition)

local condition = createConditionObject(CONDITION_HASTE)

setConditionParam(condition, CONDITION_PARAM_SPEED, 300)

setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)

setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)

setCombatCondition(combat, condition)

local condition = createConditionObject(CONDITION_REGENERATION)

setConditionParam(condition, CONDITION_PARAM_SUBID, 1)

setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)

setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)

setConditionParam(condition, CONDITION_PARAM_HEALTHGAIN, health)

setConditionParam(condition, CONDITION_PARAM_HEALTHTICKS, 1000)

setCombatCondition(combat, condition)

function onCastSpell(cid, var)

if getPlayerStorageValue(cid, 102053) ~= 1 or getCreatureCondition(cid, CONDITION_REGENERATION, 1) == false then

doCombat(cid, combat, var)

setPlayerStorageValue(cid, 102053,1)

doCreatureSay(cid, "Bijuu Chakra Mode", TALKTYPE_MONSTER)

else

doPlayerSendCancel(cid, "Sorry, you are transformed.")

end

end

 

Mesmo assim não foi :/

                                                       

 

 

                                                                                           5e1fc80227b414e178a2f7de00379363.jpg.fb527fa5863cba1c20b81b6ea6841da0.jpg                                                                                                  

Link para o post
Compartilhar em outros sites
local tempo = 180 -- tempo em segundos.
local effect = {208}
     
local ml = 15 -- quantos ira aumentar o skill de ML
local skillfist = 0 -- quantos ira aumentar o skill de Fist
local skillsword = 0 -- quantos ira aumentar o skill de SWORD
local skillaxe = 0 -- quantos ira aumentar o skill de Axe
local skillclub = 15 -- quantos ira aumentar o skill de Club
local skilldistance = 0 -- quantos ira aumentar o skill de Distance
local skillshield = 0 -- quantos ira aumentar o skill de SHIELD
local HEALTH = 25 -- A cada 1 segundo quantos aumentar de vida
LOCAL combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0)
     
local condition = createConditionObject(CONDITION_ATTRIBUTES)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_STAT_MAGICLEVEL, ml)
setConditionParam(condition, CONDITION_PARAM_SKILL_FIST, skillfist)
setConditionParam(condition, CONDITION_PARAM_SKILL_SWORD, skillsword)
setConditionParam(condition, CONDITION_PARAM_SKILL_AXE, skillaxe)
setConditionParam(condition, CONDITION_PARAM_SKILL_CLUB, skillclub)
setConditionParam(condition, CONDITION_PARAM_SKILL_DISTANCE, skilldistance)
setConditionParam(condition, CONDITION_PARAM_SKILL_SHIELD, skillshield)
setConditionParam(condition, CONDITION_PARAM_OUTFIT, outfit)
setCombatCondition(combat, condition)
     
local condition = createConditionObject(CONDITION_HASTE)
setConditionParam(condition, CONDITION_PARAM_SPEED, 300)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)
setCombatCondition(combat, condition)
     
local condition = createConditionObject(CONDITION_REGENERATION)
setConditionParam(condition, CONDITION_PARAM_SUBID, 1)
setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_HEALTHGAIN, HEALTH)
setConditionParam(condition, CONDITION_PARAM_HEALTHTICKS, 1000)
setCombatCondition(combat, condition)
                  
function magicEffect2(tempo2,tempo3,cid)
if (isCreature(cid)) then
    if getPlayerStorageValue(cid, 102053) > 0 and getCreatureCondition(cid, CONDITION_REGENERATION, 1) then
        for i=1, #effect do
        local position = {x=getPlayerPosition(cid).x, y=getPlayerPosition(cid).y, z=getPlayerPosition(cid).z}
doSendMagicEffect(position, effect[i])
        end
    end
end
end
                  
function onCastSpell(cid, var)
local position129 = {x=getPlayerPosition(cid).x+2, y=getPlayerPosition(cid).y, z=getPlayerPosition(cid).z}
if getPlayerStorageValue(cid, 102053) ~= 1 or getCreatureCondition(cid, CONDITION_REGENERATION, 1) == false then
    doCombat(cid, combat, var)
    tempo2 = 0
    while (tempo2 ~= (tempo*1000)) do
        addEvent(magicEffect2, tempo2, tempo2, tempo*1000, cid)
        tempo2 = tempo2 + 300
    end
    setPlayerStorageValue(cid, 102053,1) -- storage verifica transformado, quando = 1 player esta transformado.
    doCreatureSay(cid, "Bijuu Chakra Mode", TALKTYPE_MONSTER)
else
    doPlayerSendCancel(cid, "Sorry, you are transformed.")
end
end
Link para o post
Compartilhar em outros sites

Agora não quer fazer nem a spell :(

                                                       

 

 

                                                                                           5e1fc80227b414e178a2f7de00379363.jpg.fb527fa5863cba1c20b81b6ea6841da0.jpg                                                                                                  

Link para o post
Compartilhar em outros sites
  • Solução

Aparece algum erro ?

 

Tenta esse aqui.

 

Caso não funcione me mande a tag no spells.xml.

local tempo = 60 -- tempo em segundos.
local effect = {136} -- effect no player, caso queira apenas 1, basta remover os outros numeros.
     
local ml = 35 -- quantos ira aumentar o skill de ML
local skillfist = 35 -- quantos ira aumentar o skill de Fist
local skillsword = 35 -- quantos ira aumentar o skill de Sword
local skillaxe = 35 -- quantos ira aumentar o skill de Axe
local skillclub = 35 -- quantos ira aumentar o skill de Club
local skilldistance = 35 -- quantos ira aumentar o skill de Distance
local skillshield = 35 -- quantos ira aumentar o skill de Shield
local health = 100 -- A cada 1 segundo quantos aumentar de vida
local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0)
     
local condition = createConditionObject(CONDITION_ATTRIBUTES)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_STAT_MAGICLEVEL, ml)
setConditionParam(condition, CONDITION_PARAM_SKILL_FIST, skillfist)
setConditionParam(condition, CONDITION_PARAM_SKILL_SWORD, skillsword)
setConditionParam(condition, CONDITION_PARAM_SKILL_AXE, skillaxe)
setConditionParam(condition, CONDITION_PARAM_SKILL_CLUB, skillclub)
setConditionParam(condition, CONDITION_PARAM_SKILL_DISTANCE, skilldistance)
setConditionParam(condition, CONDITION_PARAM_SKILL_SHIELD, skillshield)
setConditionParam(condition, CONDITION_PARAM_OUTFIT, outfit)
setCombatCondition(combat, condition)
     
local condition = createConditionObject(CONDITION_HASTE)
setConditionParam(condition, CONDITION_PARAM_SPEED, 250)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)
setCombatCondition(combat, condition)
     
local condition = createConditionObject(CONDITION_REGENERATION)
setConditionParam(condition, CONDITION_PARAM_SUBID, 1)
setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE)
setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000)
setConditionParam(condition, CONDITION_PARAM_HEALTHGAIN, health)
setConditionParam(condition, CONDITION_PARAM_HEALTHTICKS, 1000)
setCombatCondition(combat, condition)
            
function magicEffect1(tempo2,tempo3,cid)
if (isCreature(cid)) then
    if getPlayerStorageValue(cid, 102053) > 0 and getCreatureCondition(cid, CONDITION_REGENERATION, 1) then
        for i=1, #effect do
        local position = {x=getPlayerPosition(cid).x+1, y=getPlayerPosition(cid).y, z=getPlayerPosition(cid).z}
doSendMagicEffect(position, effect[i])  
        end
    end
end
end
                  
function onCastSpell(cid, var)
local position127 = {x=getPlayerPosition(cid).x, y=getPlayerPosition(cid).y, z=getPlayerPosition(cid).z}
if getPlayerStorageValue(cid, 102053) ~= 1 or getCreatureCondition(cid, CONDITION_REGENERATION, 1) == false then
    doCombat(cid, combat, var)
    tempo2 = 0
    while (tempo2 ~= (tempo*1000)) do
        addEvent(magicEffect1, tempo2, tempo2, tempo*1000, cid)
        tempo2 = tempo2 + 300
    end
    setPlayerStorageValue(cid, 102053,1) -- storage verifica transformado, quando = 1 player esta transformado.
    doCreatureSay(cid, "Bijuu Chakra Mode", TALKTYPE_MONSTER)
else
    doPlayerSendCancel(cid, "Sorry, you are transformed.")
end
end
Link para o post
Compartilhar em outros sites

Ae agora foi, mas ficou com outro effect, onde vou para mudar o effect ?

                                                       

 

 

                                                                                           5e1fc80227b414e178a2f7de00379363.jpg.fb527fa5863cba1c20b81b6ea6841da0.jpg                                                                                                  

Link para o post
Compartilhar em outros sites

Vlw,mas to sem REP por hoje amanhã eu do '-'

                                                       

 

 

                                                                                           5e1fc80227b414e178a2f7de00379363.jpg.fb527fa5863cba1c20b81b6ea6841da0.jpg                                                                                                  

Link para o post
Compartilhar em outros sites

Participe da conversa

Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.

Visitante
Responder

×   Você colou conteúdo com formatação.   Remover formatação

  Apenas 75 emojis são permitidos.

×   Seu link foi automaticamente incorporado.   Mostrar como link

×   Seu conteúdo anterior foi restaurado.   Limpar o editor

×   Não é possível colar imagens diretamente. Carregar ou inserir imagens do URL.

  • Quem Está Navegando   0 membros estão online

    Nenhum usuário registrado visualizando esta página.

×
×
  • Criar Novo...

Informação Importante

Confirmação de Termo