I have tried with your script in two ways:
first:
function onUse(cid, item, frompos, item2, topos)
if item2.itemid == 2470 then
doRemoveItem(item2.uid,1)
doPlayerAddItem(cid,2160,100)
elseif item2.itemid == 2487 then
doRemoveItem(item2.uid,1)
doPlayerAddItem(cid,6527,5)
elseif...