Advertisement
Guest User

Untitled

a guest
Aug 22nd, 2014
229
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.46 KB | None | 0 0
  1. function onUse(cid, item, fromPosition, itemEx, toPosition)
  2.     local player = Player(cid)
  3.     local v = [item.actionid]
  4.     if not v then
  5.         return true
  6.     end
  7.  
  8.     if player:getStorageValue(12345) then
  9.         player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "You need to wait" . . "before you can use it again.")
  10.         player:sendMagicEffect(getThingPos, CONST_ME_POFF)
  11.     else
  12.         player:addItem(22718, 1)
  13.         player:setStorageValue(12345, os.time 20*60*60)
  14.     end
  15.     return true
  16. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement