diff options
author | TenPlus1 <kinsellaja@yahoo.com> | 2016-01-21 14:59:28 +0000 |
---|---|---|
committer | TenPlus1 <kinsellaja@yahoo.com> | 2016-01-21 14:59:28 +0000 |
commit | 87031b60518731f62dbce0ffb1601b0c34d506c9 (patch) | |
tree | 707258c7ca090302fbbc7114966d551c849881da /fences.lua | |
parent | bd0fae584c0b0c3a04d41608acb4dfaf77554d91 (diff) |
Optimize code, allfaces leaves by default, leaves walkable by default
Diffstat (limited to 'fences.lua')
-rw-r--r-- | fences.lua | 48 |
1 files changed, 25 insertions, 23 deletions
@@ -15,29 +15,31 @@ local fences = { for _, row in pairs(fences) do -minetest.register_node("ethereal:fence_"..row[1], { - description = row[2].." Fence", - drawtype = "fencelike", - is_ground_content = false, - tiles = {row[3]}, - inventory_image = "default_fence_overlay.png^"..row[3].."^default_fence_overlay.png^[makealpha:255,126,126", - wield_image = "default_fence_overlay.png^"..row[3].."^default_fence_overlay.png^[makealpha:255,126,126", - paramtype = "light", - sunlight_propagates = true, - selection_box = { - type = "fixed", - fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7}, - }, - groups = {choppy = 2, oddly_breakable_by_hand = 2, flammable = 2}, - sounds = default.node_sound_wood_defaults(), -}) + minetest.register_node("ethereal:fence_"..row[1], { + description = row[2].." Fence", + drawtype = "fencelike", + is_ground_content = false, + tiles = {row[3]}, + inventory_image = "default_fence_overlay.png^" .. row[3] + .. "^default_fence_overlay.png^[makealpha:255,126,126", + wield_image = "default_fence_overlay.png^" .. row[3] + .. "^default_fence_overlay.png^[makealpha:255,126,126", + paramtype = "light", + sunlight_propagates = true, + selection_box = { + type = "fixed", + fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7}, + }, + groups = {choppy = 2, oddly_breakable_by_hand = 2, flammable = 2}, + sounds = default.node_sound_wood_defaults(), + }) -minetest.register_craft({ - output = "ethereal:fence_"..row[1].." 4", - recipe = { - {row[4], "group:stick", row[4]}, - {row[4], "group:stick", row[4]}, - } -}) + minetest.register_craft({ + output = "ethereal:fence_"..row[1].." 4", + recipe = { + {row[4], "group:stick", row[4]}, + {row[4], "group:stick", row[4]}, + } + }) end |