Postado Novembro 22, 2014 10 anos Alguém pode min dizer porque esses ataques ta tirando vida do personagem mesmo pokemon tando vivo elseif spell == "Absorb" then local life = getCreatureHealth(target) doAreaCombatHealth(cid, GRASSDAMAGE, getThingPosWithDebug(target), 0, -min, -max, 14) local newlife = life - getCreatureHealth(target) doSendMagicEffect(getThingPosWithDebug(cid), 14) if newlife >= 1 then doCreatureAddHealth(cid, newlife) doSendAnimatedText(getThingPosWithDebug(cid), "+"..newlife.."", 32) end elseif spell == "Leech Life" then local life = getCreatureHealth(target) doDanoWithProtect(cid, BUGDAMAGE, getThingPosWithDebug(target), 0, -min, -max, 14) local newlife = life - getCreatureHealth(target) doSendMagicEffect(getThingPosWithDebug(cid), 14) if newlife >= 1 then doCreatureAddHealth(cid, newlife) doSendAnimatedText(getThingPosWithDebug(cid), "+"..newlife.."", 32) end Editado Novembro 22, 2014 10 anos por izac ximenes (veja o histórico de edições)
Postado Novembro 22, 2014 10 anos Amigo, seguinte. Não use mais cores como esse verde, dificulta a leitura. Bom, eu fiz um código simples que se o player tiver algum summon, ele irá retornar o target para este summon. for s = 1, #getCreatureSummons(cid) do if getCreatureSummons(cid)[s] then target = getCreatureSummons(cid)[s] break end end Basta implantar nas magias. Tony Araújo
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.