So I have two different types of currency in my OT. One is the standard one and the other one is the Premium Points. In my OT it came with a custom !buypremium but it only charges 20,000 and i want it to charge 50 premium points instead of that. Can someone help?
ID OF PREMIUM POINTS = 2157
THE FORGOTTEN SERVER 0.3.6 TIBIA 8.6
this is the buy premium command in my OT:
ID OF PREMIUM POINTS = 2157
THE FORGOTTEN SERVER 0.3.6 TIBIA 8.6
this is the buy premium command in my OT:
Code:
<?xml version="1.0" encoding="UTF-8"?>
<mod name="Buy premium command" version="1.0" author="The Forgotten Server" contact="otland.net" enabled="yes">
<config name="buypremium_config"><![CDATA[
config = {
days = 90,
cost = 10000,
maxDays = 360
}
]]></config>
<talkaction words="!buypremium; !pacc" event="buffer"><![CDATA[
domodlib('buypremium_config')
if(getPlayerPremiumDays(cid) > config.maxDays) then
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You can not buy more than " .. config.days + config.maxDays .. " days of Premium Account.")
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
return
end
if(not doPlayerRemoveMoney(cid, config.cost)) then
doPlayerSendCancel(cid, "You don't have enough money, " .. config.days .. " days premium account costs " .. config.cost .. " gold coins.")
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
return
end
doPlayerAddPremiumDays(cid, config.days)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You have bought " .. config.days .. " days of premium account.")
]]></talkaction>
</mod>