mRefaat
Marketing and Coding
Hello
I made this script to give a reward to players who are online every 1 hour.
But i want to prevent this reward for players with the same ip.
Any help?
TFS 0.3.7 for 8.60
I made this script to give a reward to players who are online every 1 hour.
But i want to prevent this reward for players with the same ip.
Any help?
TFS 0.3.7 for 8.60
Lua:
local time = 60 * 60 * 1 -- 1 hour
local function AddGift(cid)
if isPlayer(cid) then
doPlayerAddItem(cid, 6527, 100, 100)
doPlayerSendTextMessage(cid, 25, "You have been rewarded by 100 tokens for being online for 1 hour.")
addEvent(AddGift, time * 1000, cid)
end
end
function onLogin(cid)
addEvent(AddGift, time * 1000, cid)
return true
end