LightTenshimaru
LightTenshimaru
- Joined
- Mar 15, 2014
- Messages
- 28
- Reaction score
- 1
Hello, i've got this code to change Gold Coin into Platinum Coin automatically, but there's no console error and the gold it's not changing.
Whats wrong?
Lua:
function onThink(creature, interval)
local player = creature:getPlayer()
if not player then
return false
end
if player:getItemCount(2148) == 100 then
player:removeItem(2148, 100)
player:addItem(2152, 1)
player:sendCancelMessage('Converted 100 Gold Coins to 1 Platinum Coin.')
return true
end
end
Whats wrong?
Last edited: