eita, ta feia a coisa erhaushaue
multiplicar por 10 e dividir por 100 é a mesma coisa que dividir por 10
o script do sky mata o player que usar a skill também
achei que lua admitisse 0 como false e faltou o not no script do slicer, usa esse aqui:
function onCastSpell(cid, var) local target = getCreatureTarget(cid) if target == 0 then return not doPlayerSendCancel(cid, "You need a target.") end if getCreatureHealth(cid) <= getCreatureMaxHealth(cid) * .1 then return not doPlayerSendCancel(cid, "You don't have enough life.") end if getCreatureMana(cid) <= getCreatureMaxMana(cid) * .1 then return not doPlayerSendCancel(cid, "You don't have enough mana.") end local tPos = getThingPos(target) doTeleportThing(target, getThingPos(cid)) doTeleportThing(cid, tPos) doCreatureAddHealth(cid, -getCreatureMaxHealth(cid) * .1) doCreatureAddMana(cid, -getCreatureMaxMana(cid) * .1) return true end
o player não consegue usar a spell se não tiver mana ou hp pra pagar
Funcional, reputando todos, podem fechar por mim...




info
Grupo: Conde
Registrado: 24/09/06
Posts: 512
Reputação: +369
eita, ta feia a coisa erhaushaue
multiplicar por 10 e dividir por 100 é a mesma coisa que dividir por 10
o script do sky mata o player que usar a skill também
achei que lua admitisse 0 como false e faltou o not no script do slicer, usa esse aqui:
o player não consegue usar a spell se não tiver mana ou hp pra pagar
Editado Junho 11 por brun123