Assim?:
local evo = {
["Seel"] = "Dewgong",
}
function onUse(cid, item, fromPosition, itemEx, toPosition)
if isMonster(itemEx.uid) and getCreatureMaster(itemEx.uid) == cid then
local monster = getCreatureName(itemEx.uid)
if evo[monster] then
local health, maxHealth = getCreatureHealth(itemEx.uid), getCreatureMaxHealth(itemEx.uid)
doRemoveCreature(itemEx.uid)
doRemoveItem(item.uid)
doRemoveItem(item.uid)
local summon = doCreateMonster(evo[monster], toPosition)
doConvinceCreature(cid, summon)
doCreatureAddHealth(summon, health-maxHealth)
return TRUE
end
end
return TRUE
end





info
Grupo: Campones
Registrado: 06/11/09
Posts: 17
Reputação: +3
Aí , eu estou usando um script de envolve do Kydrai, funciona tudo correto!
Mas eu estou precisando de um que a 2º evolução precise de 2 items no caso (2 stones)
Esse é o Script:
local evo = { ["Seel"] = "Dewgong", } function onUse(cid, item, fromPosition, itemEx, toPosition) if isMonster(itemEx.uid) and getCreatureMaster(itemEx.uid) == cid then local monster = getCreatureName(itemEx.uid) if evo[monster] then local health, maxHealth = getCreatureHealth(itemEx.uid), getCreatureMaxHealth(itemEx.uid) doRemoveCreature(itemEx.uid) doRemoveItem(item.uid) local summon = doCreateMonster(evo[monster], toPosition) doConvinceCreature(cid, summon) doCreatureAddHealth(summon, health-maxHealth) return TRUE end end return TRUE endEu uso essa tag no actions.xml:
Como disse ali em cima está funcionando corretamente, mas como faço pra ter que remover 2 items (stones) do player?!
Vlw!
aguardando...