• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

GetItemByDesc

Coca Cola

New Member
Joined
Apr 10, 2010
Messages
164
Reaction score
0
i usually add desc with an identification number like [identification : 001] in some special itens , how can i get back the item by the desc?
ty,cya
 
you get item set it a action id or unique id
then say
LUA:
function onUse(cid, item, fromPosition, itemEx, toPosition)
if item.actionid == NUMBER then
   doPlayerSendCancel(cid,"Done.")
return true 
end

or like this
in action.xml you can write the aid in it:
Code:
<action actionid="NUMBER" event="script" value="balablab.lua"/>
and in lua
LUA:
function onUse(cid, item, fromPosition, itemEx, toPosition)
doPlayerSendCancel(cid,"Done")
doRemoveItem(item.uid)  ---item will be removed the item with the aid you set in action.xml
return true 
end
 
ty by helping but is different,
i create an item upgraded and put uniqueid 15000 , and if i want to delete i write /remove 15000 , xD
 
Back
Top