luigilc
Lua Learner
I made an inquisition quest on my server but when ppl go to reward room and open the chests they don't get the items
here is the reward chests script:
anyone can help me with that?
here is the reward chests script:
-- inquisition chests
function onUse(cid, item, frompos, item2, topos)
if item.uid == 1300 then
queststatus = getPlayerStorageValue(cid,6076)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22,"You have found a Cavalry Shield.")
doPlayerAddItem(cid,2013,1)
setPlayerStorageValue(cid,6076,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
elseif item.uid == 1301 then
queststatus = getPlayerStorageValue(cid,6076)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22, "You have found a Moon Staff.")
doPlayerAddItem(cid,5807,1)
setPlayerStorageValue(cid,6076,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
elseif item.uid == 1302 then
queststatus = getPlayerStorageValue(cid,6076)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22, "You have found a Fire Magician's Cape.")
doPlayerAddItem(cid,8881,1)
setPlayerStorageValue(cid,6076,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
elseif item.uid == 1303 then
queststatus = getPlayerStorageValue(cid,6076)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22, "You have found a Leviathan Armor.")
doPlayerAddItem(cid,8884,1)
setPlayerStorageValue(cid,6076,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
elseif item.uid == 1304 then
queststatus = getPlayerStorageValue(cid,6076)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22, "You have found a Slingshot.")
doPlayerAddItem(cid,5907,1)
setPlayerStorageValue(cid,6076,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
elseif item.uid == 1305 then
queststatus = getPlayerStorageValue(cid,6076)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22, "You have found a Holy Slash Sword.")
doPlayerAddItem(cid,8930,1)
setPlayerStorageValue(cid,6076,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
elseif item.uid == 1306 then
queststatus = getPlayerStorageValue(cid,6076)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22, "You have found a "You have found a Fiery Giant Armor.")
doPlayerAddItem(cid,8886,1)
setPlayerStorageValue(cid,6076,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
elseif item.uid == 1307 then
queststatus = getPlayerStorageValue(cid,6076)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22, "You have found a "You have found a Master's Instructor Robe.")
doPlayerAddItem(cid,11349,1)
setPlayerStorageValue(cid,6076,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
elseif item.uid == 1308 then
queststatus = getPlayerStorageValue(cid,6076)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22, "You have found a "You have found 1kk.")
doPlayerAddItem(cid,2160,100)
setPlayerStorageValue(cid,6076,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
else
return 0
end
return 1
end
anyone can help me with that?