summaryrefslogtreecommitdiff
path: root/node_defs.lua
diff options
context:
space:
mode:
authorVanessa Ezekowitz <vanessaezekowitz@gmail.com>2013-11-14 18:11:42 -0500
committerVanessa Ezekowitz <vanessaezekowitz@gmail.com>2013-11-14 18:11:42 -0500
commit15601c6c5156fb696b61acc9d6f094b1acbc87af (patch)
treec3ded38550c3304f06c262e855fd138e4bed8cd4 /node_defs.lua
parente1baf2018bf1faff14eaa83e65ba8fa029296e5d (diff)
Use clone node method to redefine the default apple
Diffstat (limited to 'node_defs.lua')
-rw-r--r--node_defs.lua20
1 files changed, 3 insertions, 17 deletions
diff --git a/node_defs.lua b/node_defs.lua
index 6d586e0..c3bf64a 100644
--- a/node_defs.lua
+++ b/node_defs.lua
@@ -375,23 +375,9 @@ minetest.register_node("moretrees:fir_leaves_bright", {
})
if moretrees.enable_redefine_apple then
- minetest.register_node(":default:apple", {
- description = "Apple",
- drawtype = "plantlike",
- visual_scale = 1.0,
- tiles = {"default_apple.png"},
- inventory_image = "default_apple.png",
- paramtype = "light",
- sunlight_propagates = true,
- walkable = false,
- selection_box = {
- type = "fixed",
- fixed = {-0.2, -0.5, -0.2, 0.2, 0, 0.2}
- },
- groups = {fleshy=3,dig_immediate=3,flammable=2,attached_node=1},
- on_use = minetest.item_eat(1),
- sounds = default.node_sound_defaults(),
- })
+ new_default_apple = moretrees:clone_node("default:apple")
+ new_default_apple.groups.attached_node = 1
+ minetest.register_node(":default:apple", new_default_apple)
end
table.insert(moretrees.avoidnodes, "default:jungletree")