summaryrefslogtreecommitdiff
path: root/technic_chests/register.lua
diff options
context:
space:
mode:
Diffstat (limited to 'technic_chests/register.lua')
-rw-r--r--technic_chests/register.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/technic_chests/register.lua b/technic_chests/register.lua
index 17b1a0e..0344c2c 100644
--- a/technic_chests/register.lua
+++ b/technic_chests/register.lua
@@ -49,7 +49,9 @@ end
local function check_color_buttons(pos, meta, chest_name, fields)
for i = 1, 16 do
if fields["color_button"..i] then
- technic.swap_node(pos, chest_name..colorid_to_postfix(i))
+ local node = minetest.get_node(pos)
+ node.name = chest_name..colorid_to_postfix(i)
+ minetest.swap_node(pos, node)
meta:set_string("color", i)
return
end