diff options
author | Jeija <jeija@mesecons.net> | 2014-11-22 15:42:22 +0100 |
---|---|---|
committer | Jeija <jeija@mesecons.net> | 2014-11-22 15:42:22 +0100 |
commit | 5be179bf110b44bdc06df6dbfde4e61487cf0635 (patch) | |
tree | 018eb119344d66d6229ad65607d51360fd006934 /mesecons_extrawires | |
parent | ffacbfde5a956da910479139f490f8ffa3ae5a85 (diff) |
Replace mesecon:<some_function> with mesecon.<some_function> for greater
flexibility and because it was never inteded to be OOP in the first
place.
mesecon.receptor_on and mesecon.receptor_off are provided by wrappers
(mesecon:receptor_on/off) for compatibility, but will be removed. Mod
programmers that use mesecons: Please update!
Also, fix microcontroller polluting the global namespace and remove some
deprecated stuff.
Diffstat (limited to 'mesecons_extrawires')
-rw-r--r-- | mesecons_extrawires/corner.lua | 2 | ||||
-rw-r--r-- | mesecons_extrawires/tjunction.lua | 2 | ||||
-rw-r--r-- | mesecons_extrawires/vertical.lua | 8 |
3 files changed, 6 insertions, 6 deletions
diff --git a/mesecons_extrawires/corner.lua b/mesecons_extrawires/corner.lua index d7f7a02..003275a 100644 --- a/mesecons_extrawires/corner.lua +++ b/mesecons_extrawires/corner.lua @@ -15,7 +15,7 @@ local corner_get_rules = function (node) {x = 0, y = 0, z = -1}} for i = 0, node.param2 do - rules = mesecon:rotate_rules_left(rules) + rules = mesecon.rotate_rules_left(rules) end return rules diff --git a/mesecons_extrawires/tjunction.lua b/mesecons_extrawires/tjunction.lua index c5f36a2..680dc99 100644 --- a/mesecons_extrawires/tjunction.lua +++ b/mesecons_extrawires/tjunction.lua @@ -16,7 +16,7 @@ local tjunction_get_rules = function (node) {x = 0, y = 0, z = -1}} for i = 0, node.param2 do - rules = mesecon:rotate_rules_left(rules) + rules = mesecon.rotate_rules_left(rules) end return rules diff --git a/mesecons_extrawires/vertical.lua b/mesecons_extrawires/vertical.lua index 0f153b7..c6bf34a 100644 --- a/mesecons_extrawires/vertical.lua +++ b/mesecons_extrawires/vertical.lua @@ -42,8 +42,8 @@ local vertical_updatepos = function (pos) local node = minetest.get_node(pos) if minetest.registered_nodes[node.name] and minetest.registered_nodes[node.name].is_vertical_conductor then - local node_above = minetest.get_node(mesecon:addPosRule(pos, vertical_rules[1])) - local node_below = minetest.get_node(mesecon:addPosRule(pos, vertical_rules[2])) + local node_above = minetest.get_node(mesecon.addPosRule(pos, vertical_rules[1])) + local node_below = minetest.get_node(mesecon.addPosRule(pos, vertical_rules[2])) local namestate = minetest.registered_nodes[node.name].vertical_conductor_state local above = minetest.registered_nodes[node_above.name] @@ -66,8 +66,8 @@ end local vertical_update = function (pos, node) vertical_updatepos(pos) -- this one - vertical_updatepos(mesecon:addPosRule(pos, vertical_rules[1])) -- above - vertical_updatepos(mesecon:addPosRule(pos, vertical_rules[2])) -- below + vertical_updatepos(mesecon.addPosRule(pos, vertical_rules[1])) -- above + vertical_updatepos(mesecon.addPosRule(pos, vertical_rules[2])) -- below end -- Vertical wire |