Hello
I'm wondering if its posible to make a key with a certain action id be in a chest that only can be loot once per player. have tried to use Rme. and put the key in the chest and put the action id on the key but when i try it the key is just inside the chest and u can loot it once per restart and the same player can loot it. I have done some chest that you can loot once per char. But have no ide how to make an item in the chest with a action id.
here is an example of code of a quest chest so you know what kind of codes.
Questbox.lua
Actions.xml
/R.
I'm wondering if its posible to make a key with a certain action id be in a chest that only can be loot once per player. have tried to use Rme. and put the key in the chest and put the action id on the key but when i try it the key is just inside the chest and u can loot it once per restart and the same player can loot it. I have done some chest that you can loot once per char. But have no ide how to make an item in the chest with a action id.
here is an example of code of a quest chest so you know what kind of codes.
Questbox.lua
Code:
elseif item.uid == 10609 then
queststatus = getPlayerStorageValue(cid,10609)
if queststatus == -1 then
doPlayerSendTextMessage(cid,MESSAGE_INFO_DESCR,"Here is your new start gear.")
doPlayerAddItem(cid,2457,1)
doPlayerAddItem(cid,2465,1)
doPlayerAddItem(cid,2478,1)
doPlayerAddItem(cid,2643,1)
doPlayerAddItem(cid,2456,1)
doPlayerAddItem(cid,2175,1)
doPlayerAddItem(cid,2544,100)
setPlayerStorageValue(cid,10609,1)
else
doPlayerSendTextMessage(cid,MESSAGE_INFO_DESCR,"The chest is empty.")
end
Actions.xml
Code:
<action uniqueid="10609" script="questbox.lua" />
/R.
