summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarter Kolwey <cheapiephp@gmail.com>2016-12-25 22:24:04 -0600
committerJeija <norrepli@gmail.com>2017-03-04 09:37:32 +0100
commit5e8c3584d171f9b2ae1f9af610350e249dd4aa29 (patch)
tree3f6cb5ac3c589892cce33ce8255114c60ec22e16
parentd80c788fab91d20928bb4dedaf6018a310544ca9 (diff)
Prevent rotating wires (fixes #297)
-rw-r--r--mesecons/util.lua4
1 files changed, 4 insertions, 0 deletions
diff --git a/mesecons/util.lua b/mesecons/util.lua
index 39f5696..21ceda1 100644
--- a/mesecons/util.lua
+++ b/mesecons/util.lua
@@ -179,6 +179,10 @@ end
function mesecon.register_node(name, spec_common, spec_off, spec_on)
spec_common.drop = spec_common.drop or name .. "_off"
spec_common.__mesecon_basename = name
+ if spec_common.mesecon_wire then
+ -- Prevent wires from being rotated
+ spec_common.on_rotate = false
+ end
spec_on.__mesecon_state = "on"
spec_off.__mesecon_state = "off"