samuel157
/root
- Joined
- Mar 19, 2010
- Messages
- 447
- Solutions
- 3
- Reaction score
- 49
- Location
- São Paulo, Brazil
- GitHub
- Samuel10M
storage = 54676
Lua:
local gold_cost = 0
function onSay(cid, words, param)
if getPlayerLevel(cid) >= 717217 and (getPlayerStorageValue(cid, 13545) > 0) and isPremium(cid) then
if doPlayerRemoveMoney(cid, gold_cost) then
doPlayerAddItem(cid, 5805, 1)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Voce comprou um item para desbugar a CAP.")
else
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Voce nao tem dinheiro suficiente.")
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
end
else
if getPlayerLevel(cid) < 717217 then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Voce nao tem level suficiente.")
elseif getPlayerStorageValue(cid, 13545) <= 0 then
doCreatureSay(cid, "Voce nao e VIP.", TALKTYPE_ORANGE_1)
else
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Voce nao e premium.")
end
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
end
end