Change coins muito facil esse é para Gold>Platinum>Crystal<Platinum<Gold.
Em actions.xml coloque:
<action itemid="2148" script="changecoins.lua" /><action itemid="2152" script="changecoins.lua" />
<action itemid="2160" script="changecoins.lua" />
Ou nos números coloque os ID's de GOLD>PLATINUM>CRYSTAL
e em changecoins.lua coloque:
function onUse(cid, item, frompos, item2, topos)repo = getPlayerName(cid)
if item.itemid == 2148 and item.type > 99 then
doPlayerSendTextMessage(cid,"Gold Changed",22)
doRemoveItem(item.uid,item.type)
doPlayerAddItem(cid,2152,1)
doSendMagicEffect(topos,12)
print("JLS ::Player changed gold to platinum:",repo)
end
if item.itemid == 2152 and item.type > 99 then
doPlayerSendTextMessage(cid,"Platinum Changed",22)
doRemoveItem(item.uid,item.type)
doPlayerAddItem(cid,2160,1)
doSendMagicEffect(topos,12)
print("JLS ::Player changed platinum to crystal:",repo)
end
if item.itemid == 2160 and item.type < 2 then
doPlayerSendTextMessage(cid,"Crystal Changed",22)
doRemoveItem(item.uid,item.type)
doPlayerAddItem(cid,2152,100)
doSendMagicEffect(topos,12)
print("JLS ::Player changed crystal to platinum:",repo)
end
if item.itemid == 2152 and item.type < 2 then
doPlayerSendTextMessage(cid,"Platinum Changed",22)
doRemoveItem(item.uid,item.type)
doPlayerAddItem(cid,2148,100)
doSendMagicEffect(topos,12)
print("JLS ::Player changed platinum to gold:",repo)
end
end
--- FIM DA ACTION
Você pode trocar os ids se for em 7.5 acho q os ids são diferentes.
eu poderia ter colocado + coisas, tipo pra aparecer q precisa no minimo 100 ou 1 para trocar etc.. mas isso são coisas idiotas...