Well, this is a script that basically allows you to say /DonatorItem and itll give you a item once everyLogin for 50x and it counts down.
Here we go!
And add this to your login.lua
Here we go!
LUA:
function onSay(cid, words, param)
local config = {
item = 2400,
storageID = 1337,
loginID = 1338
}
if getPlayerStorageValue(cid, config.storageID) == -1 then
doPlayerAddItem(cid,config.item,1)
setPlayerStorageValue(cid, config.storageID, 49)
doSendMagicEffect(getCreaturePosition(cid), math.random(1, 67))
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Heres your " .. getItemNameById(config.item) ..". You can use this Donator Command up to 50x and Right now you have 50x more uses.")
setPlayerStorageValue(cid, config.loginID, 2)
elseif getPlayerStorageValue(cid, config.storageID) >= 1 and getPlayerStorageValue(cid, config.loginID) == 1 then
doPlayerAddItem(cid,config.item,1)
doSendMagicEffect(getCreaturePosition(cid), math.random(1, 67))
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Heres your " .. getItemNameById(config.item) ..". You have " .. getPlayerStorageValue(cid, config.storageID) .." more uses.")
setPlayerStorageValue(cid, 1337, getPlayerStorageValue(cid, config.storageID) -1)
setPlayerStorageValue(cid, config.loginID, 2)
else
doPlayerSendTextMessage(cid,22,"You dont have Donator Rights or you have already used the command this Login.")
end
return TRUE
end
And add this to your login.lua
LUA:
setPlayerStorageValue(cid, 1338, 1)
