From d9b616c5f05b1c512988fd5eef5f91aba5bf12cf Mon Sep 17 00:00:00 2001 From: thetaepsilon-gamedev Date: Sun, 1 Oct 2017 15:47:21 +0100 Subject: new flow logic: node registry: add initial stub for flow directionality check --- new_flow_logic/flowable_node_registry.lua | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'new_flow_logic') diff --git a/new_flow_logic/flowable_node_registry.lua b/new_flow_logic/flowable_node_registry.lua index 8fb925c..b0634d0 100644 --- a/new_flow_logic/flowable_node_registry.lua +++ b/new_flow_logic/flowable_node_registry.lua @@ -26,3 +26,16 @@ pipeworks.flowables.inputs.nodenames = {} pipeworks.flowables.outputs = {} pipeworks.flowables.outputs.list = {} -- not currently any nodenames arraylist for this one as it's not currently needed. + + + +-- checks if a given node can flow in a given direction. +-- used to implement directional devices such as pumps, +-- which only visually connect in a certain direction. +-- node is the usual name + param structure. +-- direction is an x/y/z vector of the flow direction; +-- this function answers the question "can this node flow in this direction?" +pipeworks.flowables.flow_check = function(node, direction) + minetest.log("warning", "pipeworks.flowables.flow_check() stub!") + return true +end -- cgit v1.2.3