did stuff
This commit is contained in:
parent
5d62bac119
commit
68f4b5d7ea
@ -58,7 +58,6 @@ end
|
||||
local function forward()
|
||||
if turtle.forward() then
|
||||
pos = getPos()
|
||||
sleep(0.2)
|
||||
if pos["r"] == 0 then
|
||||
pos["z"] = pos["z"] + 1
|
||||
elseif pos["r"] == 1 then
|
||||
@ -69,11 +68,11 @@ local function forward()
|
||||
pos["x"] = pos["x"] + 1
|
||||
end
|
||||
savePos()
|
||||
sleep(0.3)
|
||||
end
|
||||
end
|
||||
|
||||
local function back()
|
||||
sleep(0.2)
|
||||
if turtle.back() then
|
||||
if pos["r"] == 0 then
|
||||
pos["z"] = pos["z"] - 1
|
||||
@ -85,6 +84,7 @@ local function back()
|
||||
pos["x"] = pos["x"] - 1
|
||||
end
|
||||
savePos()
|
||||
sleep(0.3)
|
||||
end
|
||||
end
|
||||
|
||||
@ -93,6 +93,7 @@ local function up()
|
||||
if turtle.up() then
|
||||
pos["y"] = pos["y"] + 1
|
||||
savePos()
|
||||
sleep(0.3)
|
||||
end
|
||||
end
|
||||
|
||||
@ -101,6 +102,7 @@ local function down()
|
||||
if turtle.down() then
|
||||
pos["y"] = pos["y"] - 1
|
||||
savePos()
|
||||
sleep(0.3)
|
||||
end
|
||||
end
|
||||
|
||||
@ -109,6 +111,7 @@ local function left()
|
||||
if turtle.turnLeft() then
|
||||
pos["r"] = (pos["r"]-1) % 4
|
||||
savePos()
|
||||
sleep(0.3)
|
||||
end
|
||||
end
|
||||
|
||||
@ -117,6 +120,7 @@ local function right()
|
||||
if turtle.turnRight() then
|
||||
pos["r"] = (pos["r"]+1) % 4
|
||||
savePos()
|
||||
sleep(0.3)
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -339,6 +339,8 @@ local function checkPosition()
|
||||
end
|
||||
end
|
||||
|
||||
-- in case the tutel needs to refuel before heading off
|
||||
inventoryRework()
|
||||
|
||||
if fs.exists "brulijam/files/state-t-fiboMiner.txt" then
|
||||
--setup()
|
||||
|
Loading…
Reference in New Issue
Block a user