From 6d335a16895b4aa35e8194a506e4ea248b1f345b Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Thu, 17 Mar 2022 04:59:42 +0100 Subject: [PATCH] Add stone, ocean stone, ocean cobble stairs --- mods/stairs/init.lua | 49 +++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 46 insertions(+), 3 deletions(-) diff --git a/mods/stairs/init.lua b/mods/stairs/init.lua index 6514f67..1b156fe 100644 --- a/mods/stairs/init.lua +++ b/mods/stairs/init.lua @@ -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") ]]