package manager + tweaks to milo

This commit is contained in:
kepler155c
2018-11-06 16:21:31 -05:00
parent d113b1da1a
commit 01452ced72
9 changed files with 117 additions and 63 deletions

View File

@@ -93,7 +93,7 @@ end
local chest = InventoryAdapter({ side = 'top', direction = 'down' }) or
error('missing chest above')
turtle.run(function()
local s, m = turtle.run(function()
turnOffWater()
repeat
@@ -117,3 +117,7 @@ turtle.run(function()
os.sleep(5)
until turtle.isAborted()
end)
if not s and m then
error(m)
end

11
farms/etc/apps/apps.db Normal file
View File

@@ -0,0 +1,11 @@
{
[ "8d1b0a73bedc0dc492377c2f6ab880940b97ec6e" ] = {
title = "Treefarm",
icon = "\030 \031f \0305 \030 \030d \030 \
\0305\031f \030d \030 \030d \0305 \030d \
\030 \031f \030c \030 \0304 \030 \030c \030 ",
category = "Apps",
run = "treefarm.lua",
requires = "turtle",
},
}

View File

@@ -106,7 +106,7 @@ local function harvest(blocks)
turtle.equip('right', 'plethora:module:2')
end
turtle.run(function()
local s, m = turtle.run(function()
local facing = scanner.getBlockMeta(0, 0, 0).state.facing
turtle.point.heading = Point.facings[facing].heading
@@ -125,3 +125,7 @@ turtle.run(function()
end
until turtle.isAborted()
end)
if not s and m then
error(m)
end