• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Storge for day

ConAn Edujawa

Member
Joined
Feb 23, 2015
Messages
457
Reaction score
17
i can found script when use X items gave me storge for one day "24 hours" and then remove storge from char
0.4
 
something like this ?
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
local daysvalue = 1 * 24 * 60 * 60
local daily = getPlayerStorageValue(cid, 18224)
if (daily == -1) then
daily = 0
end
if getPlayerStorageValue(cid, 13549) - os.time() <= 0 then
time = os.time() + daysvalue
setPlayerStorageValue(cid, 13549, time)
setPlayerStorageValue(cid, 18224, daily+1)
local daily = getPlayerStorageValue(cid, 18224)
doRemoveItem(item.uid, 1)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You done your " .. daily .. " Daily Quest. You got 1 cc.")
else
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You must wait 24 Hours to get your daily quest. Next avaiable will be at: " .. os.date("%H:%M:%S", getPlayerStorageValue(cid, 13540)) .. ".")
end
return true
end
Idea
 
Last edited:
Back
Top