summaryrefslogtreecommitdiff
path: root/pressure_logic/flowable_node_registry_install.lua
diff options
context:
space:
mode:
authorthetaepsilon-gamedev <thetaepsilon-gamedev@noreply.users.github.com>2017-10-17 23:14:26 +0100
committerthetaepsilon-gamedev <thetaepsilon-gamedev@noreply.users.github.com>2017-10-17 23:14:26 +0100
commit0a4d15d26ecc33315a5d088eace532ca3e539bbb (patch)
tree0172b1bc55cbf420bb5c1b0d5ebbbd6ed6f0ec89 /pressure_logic/flowable_node_registry_install.lua
parent909b321f3c6c866f686ae31dfc59a4a932f4d9c6 (diff)
downloadpipeworks-0a4d15d26ecc33315a5d088eace532ca3e539bbb.tar
pipeworks-0a4d15d26ecc33315a5d088eace532ca3e539bbb.tar.gz
pipeworks-0a4d15d26ecc33315a5d088eace532ca3e539bbb.tar.bz2
pipeworks-0a4d15d26ecc33315a5d088eace532ca3e539bbb.tar.xz
pipeworks-0a4d15d26ecc33315a5d088eace532ca3e539bbb.zip
pressure logic: flowable node registry: add directionfn to directional flowable entries
Diffstat (limited to 'pressure_logic/flowable_node_registry_install.lua')
-rw-r--r--pressure_logic/flowable_node_registry_install.lua7
1 files changed, 5 insertions, 2 deletions
diff --git a/pressure_logic/flowable_node_registry_install.lua b/pressure_logic/flowable_node_registry_install.lua
index a49c31a..3cd9c4d 100644
--- a/pressure_logic/flowable_node_registry_install.lua
+++ b/pressure_logic/flowable_node_registry_install.lua
@@ -43,9 +43,12 @@ end
-- Register a node as a directional flowable:
-- has a helper function which determines which nodes to consider valid neighbours.
-register.directional = function(nodename, neighbourfn)
+register.directional = function(nodename, neighbourfn, directionfn)
insertbase(nodename)
- pipeworks.flowables.list.directional[nodename] = { neighbourfn = neighbourfn }
+ pipeworks.flowables.list.directional[nodename] = {
+ neighbourfn = neighbourfn,
+ directionfn = directionfn
+ }
regwarning("directional", nodename)
end