Advertisement
markov2019

Untitled

May 28th, 2021
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.45 KB | None | 0 0
  1. local robot = require "robot"
  2. local component = require "component"
  3. local inv = component.inventory_controller
  4.  
  5. os.execute("cls")
  6. print("фарм жемчуга")
  7.  
  8. while true do
  9.   if robot.durability() < 0.2 then
  10.     robot.turnAround()
  11.     inv.equip()
  12.     robot.drop()
  13.     os.sleep(7) --время на зарядку меча
  14.     robot.suck()
  15.     inv.equip()
  16.     robot.turnAround()
  17.   end
  18.   while robot.detect() do
  19.     robot.swing()
  20.   end
  21. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement