function onSay(cid, words, param)
if getPlayerMoney(cid) >= 20000 then
if getPlayerFreeCap(cid) >= getItemWeight(2173) then
doPlayerRemoveMoney(cid, 20000)
doPlayerAddItem(cid, 2173, 1)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You have bought an amulet of loss for 20k.")
else
doPlayerSendCancel(cid, "You do not have enough capacity.")
end
else
doPlayerSendCancel(cid, "You need 20000 gold coins in order to buy an amulet of loss.")
doSendMagicEffect(getCreaturePosition(cid), CONST_ME_POFF)
end
return TRUE
end