Postado Maio 20, 2020 5 anos salve galera, estou colocando um novo gold no servidor special coin, aquele blue eye.... peguei um script aqui no tibiaking, e adicionei no meu certinho, fui fazer o teste comprei 1 item de 5kk pela alavanca, ele está comprando normalmente, remove 5 special coins e pego o item, porem tem um bug, ele está transformando de crystal coin para special coin mas nao esta de special coin para crystal.. alguem pode me ajudar? vou postar tudo aqui em baixo! changegold.lua local coins = { [2148] = { to = 2152, effect = 210 }, [2152] = { from = 2148, to = 2160, effect = 130 }, [2160] = { from = 2152, to = 10559, effect = 65 }, [10559] = { from = 2160, effect = 198 } } function onUse(cid, item, fromPosition, itemEx, toPosition) if(getPlayerFlagValue(cid, PLAYERFLAG_CANNOTPICKUPITEM)) then return false end local coin = coins[item.itemid] if(not coin) then return false end if(coin.to ~= nil and item.type == ITEMCOUNT_MAX) then doChangeTypeItem(item.uid, item.type - item.type) doPlayerAddItem(cid, coin.to, 1) doSendAnimatedText(fromPosition, "+ $$$", coins[coin.to].effect) elseif(coin.from ~= nil) then doChangeTypeItem(item.uid, item.type - 1) doPlayerAddItem(cid, coin.from, ITEMCOUNT_MAX) doSendAnimatedText(fromPosition, "- $$$", coins[coin.from].effect) end return true end
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.