function onUse(cid, item, fromPosition, itemEx, toPosition)
local monstername1 = "Thieving Squirrel"
local monstername2 = "Enraged Squirrel"
local unique = 4003
local unique2 = 4004
local unique3 = 4005
local s_mission = getPlayerStorageValue(cid, 4002)
local m_melf = getPlayerStorageValue(cid, 4003)
local s_bite = getPlayerStorageValue(cid, 4004)
if item.itemid == 11100 and item.aid == 4003 then -- tree 3
if s_mission == 5 and m_melf == 2 and s_bite >= 1 then
doRemoveItem(cid, 11100, 1)
doSendMagicEffect(toPosition, 10)
doSummonCreature("Thieving Squirrel", toPos)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_RED, "You've marked the tree, but its former inhabitant has stolen your bait! Get it before it runs away!")
setPlayerStorageValue(cid, 4003, 5)
setPlayerStorageValue(cid, 4004, -1)
end
elseif item.itemid == 11100 and item.aid == 4004 then -- tree 2
if s_bite == 2 and m_melf == 3 and s_bite >= 1 then
doSendMagicEffect(toPosition, 10)
doSummonCreature(monstername1, toPos)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_RED, "You have marked the tree but it seems someone marked it already! He is not happy with your actions and he brought friends!")
setPlayerStorageValue(cid, 4003, 4)
setPlayerStorageValue(cid, 4004, 1)
end
elseif item.itemid == 11100 and item.aid == 4005 then -- tree 1
if s_mission == 5 and m_melf == 2 and s_bite >= 3 then
doSendMagicEffect(toPosition, 10)
doSummonCreature(monstername1, toPos)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_RED, "You have marked the tree, but you also angered the squirrel family who lived on it!")
setPlayerStorageValue(cid, 4003, 3)
setPlayerStorageValue(cid, 4004, 2)
else
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_RED, "Fail!")
end
end
return true
end
PRECISO DE AJUDA NESSE SCRIPT É DA MISSÃO 2 DA NEW FRONTIER AONDE TEM QUE O USAR O POTE DE VENENO NAS 3 ARVORES.
Question
Everson Miranda 2
PRECISO DE AJUDA NESSE SCRIPT É DA MISSÃO 2 DA NEW FRONTIER AONDE TEM QUE O USAR O POTE DE VENENO NAS 3 ARVORES.
NÃO ESTÁ FUNCIONANDO MEU SCRIPT NÃO SEI PORQUE.
ALQUEM PODE ME AJUDAR??
+REP
Link to post
Share on other sites
1 answer to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now