samuel157
/root
- Joined
- Mar 19, 2010
- Messages
- 447
- Solutions
- 3
- Reaction score
- 49
- Location
- São Paulo, Brazil
- GitHub
- Samuel10M
Vip storage = 13545 Reset Storage vip 54676 and reset free 54676
Lua:
local config = {
vipstorage = 11551,
status = MESSAGE_STATUS_CONSOLE_BLUE,
vipstatus = MESSAGE_STATUS_CONSOLE_RED
};
function onSay(cid, words, param)
if param == "" then
doPlayerSendTextMessage(cid, (config.status), "Use one of these params: vip, hp, mana, lvl, maglvl, all")
elseif param == "vip" then
if getPlayerStorageValue(cid, (config.vipstorage)) then
doPlayerSendTextMessage(cid, (config.vipstatus), "You are VIP.")
else
doPlayerSendTextMessage(cid, (config.vipstatus), "You are no VIP.")
end
elseif param == "premium" then
if getPlayerPremiumDays(cid) > 0 then
doPlayerSendTextMessage(cid, (config.vipstatus), "You are premium and you have: " .. getPlayerPremiumDays(cid) .. " days left.")
else
doPlayerSendTextMessage(cid, (config.vipstatus), "You are no premium.")
end
elseif param == "hp" then
doPlayerSendTextMessage(cid, (config.status), "Your health is: " .. getCreatureHealth(cid) .. "/".. getCreatureMaxHealth(cid) .." hp.")
elseif param == "mana" then
doPlayerSendTextMessage(cid, (config.status), "Your mana is: " .. getCreatureMaxMana(cid) .. "/" .. getCreatureMaxMana(cid) .." mana.")
elseif param == "lvl" then
doPlayerSendTextMessage(cid, (config.status), "Your current level is: " .. getPlayerLevel(cid) .. ".")
elseif param == "maglvl" then
doPlayerSendTextMessage(cid, (config.status), "Your current magic level is: " .. getPlayerMagLevel(cid) ..".")
elseif param == "all" then
doPlayerSendTextMessage(cid, 27, "Your health is: " .. getCreatureHealth(cid) .. "/" .. getCreatureMaxHealth(cid) .. " hp.\nYour mana is: " .. getCreatureMana(cid) .. "/" .. getCreatureMaxMana(cid) .. " mana.\nYour current level is: " .. getPlayerLevel(cid) .. ".\nYour current magic level is: " .. getPlayerMagLevel(cid) .. ".")
if getPlayerStorageValue(cid, (config.vipstorage)) then
doPlayerSendTextMessage(cid, (config.vipstatus), "You are VIP.")
else
doPlayerSendTExtMessage(cid, (config.vipstatus), "You are no VIP.")
end
if getPlayerPremiumDays(cid) > 0 then
doPlayerSendTextMessage(cid, (config.vipstatus), "You are premium and you have: " .. getPlayerPremiumDays(cid) .. " days left.")
else
doPlayerSendTextMessage(cid, (config.vipstatus), "You are no premium.")
end
end
return TRUE
end
Code:
Code: