summaryrefslogtreecommitdiff
path: root/gates.lua
diff options
context:
space:
mode:
authorTenPlus1 <kinsellaja@yahoo.com>2016-01-21 14:59:28 +0000
committerTenPlus1 <kinsellaja@yahoo.com>2016-01-21 14:59:28 +0000
commit87031b60518731f62dbce0ffb1601b0c34d506c9 (patch)
tree707258c7ca090302fbbc7114966d551c849881da /gates.lua
parentbd0fae584c0b0c3a04d41608acb4dfaf77554d91 (diff)
Optimize code, allfaces leaves by default, leaves walkable by default
Diffstat (limited to 'gates.lua')
-rw-r--r--gates.lua12
1 files changed, 9 insertions, 3 deletions
diff --git a/gates.lua b/gates.lua
index f669615..b351582 100644
--- a/gates.lua
+++ b/gates.lua
@@ -26,6 +26,7 @@ function gate_rightclick(pos, node)
end
node.name = split[1] .. "_" .. split[2] .. "_" .. name
+
minetest.swap_node(pos, node)
minetest.sound_play("doors_door_"..sound, {
@@ -60,7 +61,10 @@ minetest.register_node("ethereal:fencegate_"..row[1].."_open", {
sunlight_propagates = true,
is_ground_content = false,
walkable = true,
- groups = {snappy = 1, choppy = 2, oddly_breakable_by_hand = 2, flammable = 2, not_in_inventory = 1},
+ groups = {
+ snappy = 1, choppy = 2, oddly_breakable_by_hand = 2,
+ flammable = 2, not_in_inventory = 1
+ },
drop = "ethereal:fencegate_"..row[1].."_closed",
drawtype = "nodebox",
node_box = {
@@ -93,8 +97,10 @@ minetest.register_alias("ethereal:"..row[1].."gate_open", "ethereal:fencegate_".
minetest.register_node("ethereal:fencegate_"..row[1].."_closed", {
description = row[2].." Gate",
tiles = {row[3]},
- inventory_image = "default_gate_overlay.png^"..row[3].."^default_gate_overlay.png^[makealpha:255,126,126",
- wield_image = "default_gate_overlay.png^"..row[3].."^default_gate_overlay.png^[makealpha:255,126,126",
+ inventory_image = "default_gate_overlay.png^" .. row[3]
+ .. "^default_gate_overlay.png^[makealpha:255,126,126",
+ wield_image = "default_gate_overlay.png^" .. row[3]
+ .. "^default_gate_overlay.png^[makealpha:255,126,126",
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,