Add stone, ocean stone, ocean cobble stairs

master
Wuzzy 2022-03-17 04:59:42 +01:00
parent ea38035d25
commit 6d335a1689
1 changed files with 46 additions and 3 deletions

View File

@ -327,19 +327,23 @@ function stairs.register_stair_and_slab(subname, recipeitem, groups, images,
end
-- Local function so we can apply translations
local function my_register_stair_and_slab(subname, recipeitem, groups, images,
desc_stair, desc_slab, sounds, worldaligntex)
local function my_register_stair(subname, recipeitem, groups, images,
desc_stair, sounds, worldaligntex)
stairs.register_stair(subname, recipeitem, groups, images, S(desc_stair),
sounds, worldaligntex)
stairs.register_stair_inner(subname, recipeitem, groups, images, "",
sounds, worldaligntex, T("Inner " .. desc_stair))
stairs.register_stair_outer(subname, recipeitem, groups, images, "",
sounds, worldaligntex, T("Outer " .. desc_stair))
end
local function my_register_stair_and_slab(subname, recipeitem, groups, images,
desc_stair, desc_slab, sounds, worldaligntex)
my_register_stair(subname, recipeitem, groups, images,
desc_stair, sounds, worldaligntex)
stairs.register_slab(subname, recipeitem, groups, images, S(desc_slab),
sounds, worldaligntex)
end
-- Register default stairs and slabs
my_register_stair_and_slab(
@ -352,6 +356,36 @@ my_register_stair_and_slab(
lzr_sounds.node_sound_wood_defaults(),
true
)
my_register_stair(
"stone",
"lzr_core:stone",
{breakable=1},
{"default_stone.png"},
"Stone Stair",
lzr_sounds.node_sound_stone_defaults(),
true
)
my_register_stair(
"ocean_stone",
"lzr_decor:ocean_stone",
{breakable=1},
{"xocean_stone.png"},
"Ocean Stone Stair",
lzr_sounds.node_sound_stone_defaults(),
true
)
my_register_stair(
"ocean_cobble",
"lzr_decor:ocean_cobble",
{breakable=1},
{"xocean_cobble.png"},
"Ocean Cobblestone Stair",
lzr_sounds.node_sound_stone_defaults(),
true
)
-- Dummy calls to S() to allow translation scripts to detect the strings.
-- To update this add this code to my_register_stair_and_slab:
@ -363,4 +397,13 @@ S("Wooden Stair")
S("Inner Wooden Stair")
S("Outer Wooden Stair")
S("Wooden Slab")
S("Stone Stair")
S("Inner Stone Stair")
S("Outer Stone Stair")
S("Ocean Stone Stair")
S("Inner Ocean Stone Stair")
S("Outer Ocean Stone Stair")
S("Ocean Cobblestone Stair")
S("Inner Ocean Cobblestone Stair")
S("Outer Ocean Cobblestone Stair")
]]