MaXwEllDeN

30minLogin.lua

Apr 24th, 2013
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.38 KB | None | 0 0
  1. local config = {
  2.     min_online = 30,
  3.     text = "Opa, tô a um tempão online.",
  4. }
  5.  
  6. function onThink()
  7.     for _, uid in pairs(getPlayersOnline()) do
  8.         if getPlayerStorageValue(uid, 70321) ~= -1 and os.time() - getPlayerStorageValue(uid, 70321) >= config.min_online * 60 then
  9.             doCreatureSay(uid, config.text)
  10.             setPlayerStorageValue(uid, 70321, -1)
  11.         end
  12.     end
  13.     return true
  14. end
Advertisement
Add Comment
Please, Sign In to add comment