Kramer infernal
I work alone =/
- Joined
- Jun 18, 2008
- Messages
- 225
- Reaction score
- 0
This is my problem, I want to some or someone retire a object with action ID, however, the npc couldn't handle this, so I get to switches and action id, however, it doesn't work neither, here I have the code, because I don't know what to do now...
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
playerPos = getPlayerPosition(cid)
local quest = getPlayerStorageValue(cid,8002)
if quest == 2 then
if getPlayerItemCount(cid,5710).actionid == 8002 then
doPlayerRemoveItem(cid,5710).actionid = 8002
doPlayerSendTextMessage(cid,22,'Oh thanks for bring me back my shovel! Take the wisdom of the worker and an additional fee!')
doPlayerAddItem(cid,2152,70)
doPlayerAddExp(cid,8000)
setPlayerStorageValue(cid,8002,3)
end
else
doCreatureSay(cid, 'I\'m not ready to switch this.', TALKTYPE_ORANGE_1)
return TRUE
end
end