From 09dc9951ab2c8f4dca9c602b4dad3ecb24e44eeb Mon Sep 17 00:00:00 2001 From: loosewheel <76670709+loosewheel@users.noreply.github.com> Date: Fri, 19 Nov 2021 10:37:11 +1000 Subject: [PATCH] Add files via upload --- docs/api.txt | 2 +- docs/breaker.txt | 28 ++++++++++++++--------- docs/deployer.txt | 57 +++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 76 insertions(+), 11 deletions(-) create mode 100644 docs/deployer.txt diff --git a/docs/api.txt b/docs/api.txt index 1b0621f..aba7333 100644 --- a/docs/api.txt +++ b/docs/api.txt @@ -34,7 +34,7 @@ lwcomponents.register_spawner (itemname, spawn_func) This function should return the ObjectRef of the spawned entity or nil. If this function returns nil for ObjectRef a second boolean - value should be returned for weather to cancel the action. + value should be returned for whether to cancel the action. eg. If too many mobs: return nil, true diff --git a/docs/breaker.txt b/docs/breaker.txt index 12c1883..c854f6a 100644 --- a/docs/breaker.txt +++ b/docs/breaker.txt @@ -2,11 +2,12 @@ Breaker ------- * This block is only available if digilines and/or mesecons are loaded. -Breakers dig the node directly in front of them and drop the item at the -back of them. The node is only dug if the breaker has a tool that can -dig it, of if it can be dug by hand. The tool is worn if used. Also acts -as a digilines conductor. If the hopper mod is loaded, will take tools -from the top and sides. +Breakers dig the node up to 5 nodes directly in front of them and drop +the item at the back of them. The node is only dug if the breaker has a +tool that can dig it or if it can be dug by hand, and there are no nodes +before of it. ie. cannot dig 2nd node if 1st node has something in it. +The tool is worn if used. Also acts as a digilines conductor. If the +hopper mod is loaded, will take tools from the top and sides. Only the owner can dig or access the form of the locked version. @@ -17,23 +18,26 @@ Top 1 slot inventory - tool to use. Bottom 32 slot inventory - player's inventory. Mesecons - Digs the node in front when power is turned on, if it can. + Digs the node in front (always the 1st node position) when power is + turned on, if it can. Digilines messages -"break" - Digs the node in front when power is turned on, if it can. +"break n" + Digs the node at n nodes in front when power is turned on, if it can. + n should be a number between 1 and 5. If omitted 1 is assumed. "eject side" Drop the tool in the tool slot at the given side. Valid sides are "left", "right", "back", "front". If side is omitted or invalid "front" is used. When a breaker digs a node or wears out the tool a digilines message is -sent with the puncher's channel. The message is a table with the following +sent with the breaker's channel. The message is a table with the following keys: { action = "", - name = "" + name = "", + range = } action @@ -42,3 +46,7 @@ action name For "break" action the registered node name of what was dug. For "tool" action the registered tool name of the tool that wore out. + +range + For "break" action the nodes forward that was dug. + For "tool" action always nil. diff --git a/docs/deployer.txt b/docs/deployer.txt new file mode 100644 index 0000000..a3280c8 --- /dev/null +++ b/docs/deployer.txt @@ -0,0 +1,57 @@ +Deployer +------- +* This block is only available if digilines and/or mesecons are loaded. + +Deployers place the node up to 5 nodes directly in front of them. The +node is only placed if there are no nodes before of it which are not +replaceable. ie. cannot place 2nd node if 1st node has something in it. +Also acts as a digilines conductor. If the hopper mod is loaded, will +take items from the top and sides, and release them from the bottom. + +Only the owner can dig or access the form of the locked version. + +UI + +Channel - digilines channel of breaker. +Top 16 slot inventory - storage of items to place. +Bottom 32 slot inventory - player's inventory. + +Mesecons + Places the node in front (always the 1st node position) when power is + turned on, if it can. + +Digilines messages + +"deploy " + Places the node at n nodes in front when power is turned on, if it can. + n should be a number between 1 and 5. If omitted 1 is assumed. + + If slot is a number, places an item from that slot. No placement if + slot is empty. + eg. "deploy 7" + + If itemname is given, places the item of the name given. No placement + if deployer does not contain the item. + eg. "deploy default:stone" + + If n is given with no slot/itemname use "nil". + eg. "deploy nil 3" + +When a deployer places a node a digilines message is sent with the +deployer's channel. The message is a table with the following +keys: +{ + action = "deploy", + name = "", + slot = , + range = +} + +action + Will be "deploy". + +name + The registered node name of what was placed. + +range + The nodes forward that was placed.