Advertisement
MrTrala

Droper - Trala

Jul 19th, 2016
158
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.49 KB | None | 0 0
  1. --[[
  2.     Droper
  3.     Version 1.0.1
  4.     By Mr Trala
  5.    
  6. Instructions;
  7. Just put the item id you want to throw away in Config > Drop.
  8. It will throw away that item if you have 2 or more of that item.
  9. ]]
  10.  
  11.  
  12. config = {
  13.     Drop = {3031, 3035} -- Just put the item ids you want to throw away
  14. }
  15.  
  16. function Drop()
  17. local p = Self.Position()
  18.     for _, n in pairs(config.Drop) do
  19.         if Self.ItemCount(n) >= 2 then
  20.             Self.DropItem(p.x, p.y, p.z, n)
  21.         end
  22.     end
  23. end
  24.  
  25. registerEventListener(TIMER_TICK, "Drop")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement