marcos16
Falkhonn
- Joined
- May 4, 2012
- Messages
- 224
- Reaction score
- 1
I'm using this mod for players to buy premium. But some people complain that the premium lasts 12 hr / 15 hr. And it does not last 24 hours. Could anyone help?
XML:
<?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 = 1,
cost = 1,
maxDays = 360
}
]]></config>
<talkaction words="!buyvip; !pacc" event="buffer"><![CDATA[
domodlib('buypremium_config')
if(getPlayerPremiumDays(cid) > config.maxDays) then
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You have reached your maximum VIP limit.")
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
return
end
if (not doPlayerRemoveItem(cid, 10571, 1)) then
doPlayerSendCancel(cid, "You do not have vip coin.")
return
end
doPlayerAddPremiumDays(cid, config.days)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You bought ".. config.days .." VIP day..")
]]></talkaction>
</mod>