forked from mtcontrib/riesenpilz
Fix fence registration
This commit is contained in:
parent
739d63eeda
commit
cd44a194ec
11
init.lua
11
init.lua
@ -895,7 +895,7 @@ local head_sounds = default.node_sound_wood_defaults({
|
|||||||
dig = {name="riesenpilz_head", gain=0.2},
|
dig = {name="riesenpilz_head", gain=0.2},
|
||||||
dug = {name="riesenpilz_stem", gain=0.1}
|
dug = {name="riesenpilz_stem", gain=0.1}
|
||||||
})
|
})
|
||||||
local add_fence = minetest.register_fence
|
local add_fence = default.register_fence
|
||||||
local node_groups = {oddly_breakable_by_hand=3, fall_damage_add_percent=-80, bouncy=10}
|
local node_groups = {oddly_breakable_by_hand=3, fall_damage_add_percent=-80, bouncy=10}
|
||||||
|
|
||||||
for _,i in pairs({
|
for _,i in pairs({
|
||||||
@ -1034,7 +1034,14 @@ for _,i in pairs({
|
|||||||
|
|
||||||
if add_fence
|
if add_fence
|
||||||
and i.fence ~= false then
|
and i.fence ~= false then
|
||||||
add_fence({fence_of = nodename})
|
add_fence(
|
||||||
|
nodename.."_fence",
|
||||||
|
{
|
||||||
|
material = nodename,
|
||||||
|
texture = textures[#textures],
|
||||||
|
groups = node_groups,
|
||||||
|
sounds = sounds,
|
||||||
|
})
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user