Compare commits
4 Commits
Author | SHA1 | Date | |
---|---|---|---|
b99d3a61bc | |||
8e08e4be26 | |||
76f022ec5c | |||
67a8d95fa5 |
59
nodes.lua
59
nodes.lua
@ -12,7 +12,8 @@ local sound_wood = moreblocks.node_sound_wood_defaults()
|
|||||||
local sound_stone = moreblocks.node_sound_stone_defaults()
|
local sound_stone = moreblocks.node_sound_stone_defaults()
|
||||||
local sound_glass = moreblocks.node_sound_glass_defaults()
|
local sound_glass = moreblocks.node_sound_glass_defaults()
|
||||||
local sound_leaves = moreblocks.node_sound_leaves_defaults()
|
local sound_leaves = moreblocks.node_sound_leaves_defaults()
|
||||||
|
local sound_gravel = default.node_sound_gravel_defaults()
|
||||||
|
local sound_sand = default.node_sound_sand_defaults()
|
||||||
-- Don't break on 0.4.14 and earlier.
|
-- Don't break on 0.4.14 and earlier.
|
||||||
local sound_metal = (moreblocks.node_sound_metal_defaults
|
local sound_metal = (moreblocks.node_sound_metal_defaults
|
||||||
and moreblocks.node_sound_metal_defaults() or sound_stone)
|
and moreblocks.node_sound_metal_defaults() or sound_stone)
|
||||||
@ -39,7 +40,6 @@ end
|
|||||||
local deprecated = (" ("..S('Deprecated')..")")
|
local deprecated = (" ("..S('Deprecated')..")")
|
||||||
|
|
||||||
-- start gravel add part 1
|
-- start gravel add part 1
|
||||||
local sound_gravel = default.node_sound_gravel_defaults()
|
|
||||||
|
|
||||||
local box_slope = {
|
local box_slope = {
|
||||||
type = "fixed",
|
type = "fixed",
|
||||||
@ -939,36 +939,39 @@ local nodes = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
for name, def in pairs(nodes) do
|
for name, def in pairs(nodes) do
|
||||||
def.is_ground_content = def.is_ground_content == true
|
if name ~= "tar" then
|
||||||
def.tiles = def.tiles or {"moreblocks_" ..name.. ".png"}
|
--homedecor errors, aliasing error suppress
|
||||||
minetest.register_node("moreblocks:" ..name, def)
|
def.is_ground_content = def.is_ground_content == true
|
||||||
minetest.register_alias(name, "moreblocks:" ..name)
|
def.tiles = def.tiles or {"moreblocks_" ..name.. ".png"}
|
||||||
|
minetest.register_node("moreblocks:" ..name, def)
|
||||||
|
minetest.register_alias(name, "moreblocks:" ..name)
|
||||||
|
|
||||||
def_copy = table.copy(def)
|
def_copy = table.copy(def)
|
||||||
|
|
||||||
-- Use the primary tile for all sides of cut glasslike nodes.
|
-- Use the primary tile for all sides of cut glasslike nodes.
|
||||||
-- This makes them easier to see
|
-- This makes them easier to see
|
||||||
if
|
if
|
||||||
#def_copy.tiles > 1 and
|
#def_copy.tiles > 1 and
|
||||||
def_copy.drawtype and
|
def_copy.drawtype and
|
||||||
def_copy.drawtype == "glasslike_framed" or
|
def_copy.drawtype == "glasslike_framed" or
|
||||||
def_copy.drawtype == "glasslike_framed_optional"
|
def_copy.drawtype == "glasslike_framed_optional"
|
||||||
then
|
then
|
||||||
def.tiles = {def_copy.tiles[1]}
|
def.tiles = {def_copy.tiles[1]}
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
if not def.no_stairs then
|
if not def.no_stairs then
|
||||||
local groups = {}
|
local groups = {}
|
||||||
for k, v in pairs(def.groups) do groups[k] = v end
|
for k, v in pairs(def.groups) do groups[k] = v end
|
||||||
stairsplus:register_all("moreblocks", name, "moreblocks:" ..name, {
|
stairsplus:register_all("moreblocks", name, "moreblocks:" ..name, {
|
||||||
description = def.description,
|
description = def.description,
|
||||||
groups = groups,
|
groups = groups,
|
||||||
tiles = def.tiles,
|
tiles = def.tiles,
|
||||||
sunlight_propagates = def.sunlight_propagates,
|
sunlight_propagates = def.sunlight_propagates,
|
||||||
light_source = def.light_source,
|
light_source = def.light_source,
|
||||||
sounds = def.sounds,
|
sounds = def.sounds,
|
||||||
})
|
})
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user