Começando pela Blessed Wooden Stake:
Crie um Blessed_Wooden_Stake.lua em data\actions\scripts e coloque:
---- Blessed Wooden Stake ------ Mokerhamer --
function onUse(cid, item, frompos, item2, topos)
if item2.itemid == 0 then
return 0
end
random = math.random(1,15)
if getPlayerLevel(cid) >= 1 then
if item2.itemid == 2916 and random == 1 then
doTransformItem(item2.uid,2917)
doSendMagicEffect(topos, 12)
doPlayerAddItem(cid,5906,1)
doSendAnimatedText(frompos,"~success~",18);
elseif item2.itemid == 2916 and random >= 2 then
doSendMagicEffect(topos, 3)
doTransformItem(item2.uid,2917)
end
end
random = math.random(1,15)
if getPlayerLevel(cid) >= 1 then
if item2.itemid == 2956 and random == 1 then
doSendMagicEffect(topos, 12)
doTransformItem(item2.uid,2957)
doPlayerAddItem(cid,5905,1)
doSendAnimatedText(frompos,"~success~",18);
elseif item2.itemid == 2956 and random >= 2 then
doSendMagicEffect(topos, 3)
doTransformItem(item2.uid,2957)
end
end
doPlayerSendCancel(cid,"You cant make dust of this.")
return 1
end
-------------------------------------------------------------------------------------
Agora a Obsidian Knife:
Crie um Obsidian_Knife.lua em data\actions\scripts e coloque:
---- Obsidian Knife ------ Mokerhamer --
function skinMonster(cid,item,skin)
local random = math.random(1,15)
if(random < 4) then
doPlayerAddItem(cid,skin,1)
doSendMagicEffect(getThingPos(item.uid), CONST_ME_MAGIC_GREEN)
else
doSendMagicEffect(getThingPos(item.uid), CONST_ME_BLOCKHIT)
end
doTransformItem(item.uid,item.itemid+1)
end
minotaurs = {2830, 2871, 2866, 2876}
lizards = {4259, 4262, 4251}
greendragons = {3104, 2844}
reddragons = {2881}
behemoth = {2931}
bonebeast = {3031}
cube = {7441, 7444, 7445}
cube2 = {7442}
function onUse(cid, item, fromPosition, itemEx, toPosition)
local random = math.random(1,10)
if isInArray(minotaurs, itemEx.itemid) == TRUE then
skinMonster(cid, itemEx, 5878)
elseif isInArray(lizards, itemEx.itemid) == TRUE then
skinMonster(cid, itemEx, 5876)
elseif isInArray(greendragons, itemEx.itemid) == TRUE then
skinMonster(cid, itemEx, 5877)
elseif isInArray(reddragons, itemEx.itemid) == TRUE then
skinMonster(cid, itemEx, 5948)
elseif isInArray(behemoth, itemEx.itemid) == TRUE then
skinMonster(cid, itemEx, 5893)
elseif isInArray(bonebeast, itemEx.itemid) == TRUE then
skinMonster(cid, itemEx, 5925)
elseif isInArray(cube, itemEx.itemid) == TRUE and random < 4 then
doSendMagicEffect(getThingPos(itemEx.uid), CONST_ME_HITAREA)
doTransformItem(itemEx.uid, itemEx.itemid + 1)
elseif isInArray(cube2, itemEx.itemid) == TRUE and random < 4 then
doSendMagicEffect(getThingPos(itemEx.uid), CONST_ME_HITAREA)
doTransformItem(itemEx.uid, itemEx.itemid + 2)
elseif (isInArray(cube, itemEx.itemid) == TRUE or isInArray(cube2, itemEx.itemid) == TRUE) and random > 4 then
doSendMagicEffect(getThingPos(itemEx.uid), CONST_ME_HITAREA)
doRemoveItem(itemEx.uid)
else
doPlayerSendCancel(cid,"Sorry, not possible.")
return TRUE
end
end
---------------------------------------------------------------
No Actions.xml em Data\Actions adicione:
<action itemid="5908" script="Obsidian_Knife.lua" /><action itemid="5942" script="Blessed_Wooden_Stake.lua" />
Créditos de Mokerhammer por Fazer e Pra Mim por Repassar.