Bamboo Extras intermediate changes 2

Added in Green variant
This commit is contained in:
Michieal 2023-01-19 20:22:39 -05:00
parent 445ccee598
commit 004603ff78
13 changed files with 71 additions and 15 deletions

View File

@ -8,6 +8,7 @@
local modname = minetest.get_current_modname()
local S = minetest.get_translator(modname)
local bamboo = "mcl_bamboo:bamboo"
local BROKEN_DOORS = true
local function tiki_lamp()
if minetest.get_modpath("mcl_lanterns") then
@ -37,7 +38,7 @@ local function green_bamboo_doors()
local BAMBOO_BLOCK = "mcl_bamboo:bamboo_block"
if minetest.get_modpath("mcl_doors") and mcl_doors then
minetest.register_craft({
output = "mcl_bamboo:bamboo_door2 3",
output = "mcl_bamboo:bamboo_trapdoor_green 3",
recipe = {
{BAMBOO_BLOCK, BAMBOO_BLOCK},
{BAMBOO_BLOCK, BAMBOO_BLOCK},
@ -45,7 +46,7 @@ local function green_bamboo_doors()
}
})
minetest.register_craft({
output = "mcl_bamboo:bamboo_trapdoor2 2",
output = "mcl_bamboo:bamboo_trapdoor_green 2",
recipe = {
{BAMBOO_BLOCK, BAMBOO_BLOCK, BAMBOO_BLOCK},
{BAMBOO_BLOCK, BAMBOO_BLOCK, BAMBOO_BLOCK},
@ -59,18 +60,18 @@ local function green_bamboo_doors()
local bot_door_tiles = {}
if BROKEN_DOORS then
top_door_tiles = {"mcl_bamboo_door_top_alt.png", "mcl_bamboo_door_top.png"}
bot_door_tiles = {"mcl_bamboo_door_bottom_alt.png", "mcl_bamboo_door_bottom.png"}
top_door_tiles = {"mcl_bamboo_door_top_alt_green.png", "mcl_bamboo_door_top_side_green.png"}
bot_door_tiles = {"mcl_bamboo_door_bottom_alt_green.png", "mcl_bamboo_door_bottom_side_green.png"}
else
top_door_tiles = {"mcl_bamboo_door_top.png", "mcl_bamboo_door_top.png"}
bot_door_tiles = {"mcl_bamboo_door_bottom.png", "mcl_bamboo_door_bottom.png"}
top_door_tiles = {"mcl_bamboo_door_top_green.png", "mcl_bamboo_door_top_side_green.png"}
bot_door_tiles = {"mcl_bamboo_door_bottom.png_green", "mcl_bamboo_door_bottom_side_green.png"}
end
local name = "mcl_bamboo:bamboo_door2"
local name = "mcl_bamboo:bamboo_door_green"
local def = {
description = S("Bamboo Door."),
inventory_image = "mcl_bamboo_door_wield.png",
wield_image = "mcl_bamboo_door_wield.png",
inventory_image = "mcl_bamboo_door_wield_green.png",
wield_image = "mcl_bamboo_door_wield_green.png",
groups = {handy = 1, axey = 1, material_wood = 1, flammable = -1},
_mcl_hardness = 3,
_mcl_blast_resistance = 3,
@ -81,17 +82,17 @@ local function green_bamboo_doors()
mcl_doors:register_door(name, def)
name = "mcl_bamboo:bamboo_trapdoor2"
name = "mcl_bamboo:bamboo_trapdoor_green"
local trap_def = {
description = S("Bamboo Trapdoor."),
inventory_image = "mcl_bamboo_door_complete.png",
inventory_image = "mcl_bamboo_trapdoor_side_green.png",
groups = {},
tile_front = "mcl_bamboo_trapdoor_top.png",
tile_side = "mcl_bamboo_trapdoor_side.png",
tile_front = "mcl_bamboo_trapdoor_side_green.png",
tile_side = "mcl_bamboo_trapdoor_side_green.png",
_doc_items_longdesc = S("Wooden trapdoors are horizontal barriers which can be opened and closed by hand or a redstone signal. They occupy the upper or lower part of a block, depending on how they have been placed. When open, they can be climbed like a ladder."),
_doc_items_usagehelp = S("To open or close the trapdoor, rightclick it or send a redstone signal to it."),
wield_image = "mcl_bamboo_trapdoor_wield.png",
inventory_image = "mcl_bamboo_trapdoor_wield.png",
wield_image = "mcl_bamboo_trapdoor_side.png",
inventory_image = "mcl_bamboo_trapdoor_inventory.png",
groups = {handy = 1, axey = 1, mesecon_effector_on = 1, material_wood = 1, flammable = -1},
_mcl_hardness = 3,
_mcl_blast_resistance = 3,
@ -106,6 +107,61 @@ local function green_bamboo_doors()
end
end
local function bamboo_doors_original()
if minetest.get_modpath("mcl_doors") then
if mcl_doors then
local top_door_tiles = {}
local bot_door_tiles = {}
if BROKEN_DOORS then
top_door_tiles = {"mcl_bamboo_door_top_alt.png", "mcl_bamboo_door_top.png"}
bot_door_tiles = {"mcl_bamboo_door_bottom_alt.png", "mcl_bamboo_door_bottom.png"}
else
top_door_tiles = {"mcl_bamboo_door_top.png", "mcl_bamboo_door_top.png"}
bot_door_tiles = {"mcl_bamboo_door_bottom.png", "mcl_bamboo_door_bottom.png"}
end
local name = "mcl_bamboo:bamboo_door"
local def = {
description = S("Bamboo Door."),
inventory_image = "mcl_bamboo_door_wield.png",
wield_image = "mcl_bamboo_door_wield.png",
groups = {handy = 1, axey = 1, material_wood = 1, flammable = -1},
_mcl_hardness = 3,
_mcl_blast_resistance = 3,
tiles_bottom = bot_door_tiles,
tiles_top = top_door_tiles,
sounds = mcl_sounds.node_sound_wood_defaults(),
}
mcl_doors:register_door(name, def)
name = "mcl_bamboo:bamboo_trapdoor"
local trap_def = {
description = S("Bamboo Trapdoor."),
inventory_image = "mcl_bamboo_door_complete.png",
groups = {},
tile_front = "mcl_bamboo_trapdoor_side.png",
tile_side = "mcl_bamboo_trapdoor_side.png",
_doc_items_longdesc = S("Wooden trapdoors are horizontal barriers which can be opened and closed by hand or a redstone signal. They occupy the upper or lower part of a block, depending on how they have been placed. When open, they can be climbed like a ladder."),
_doc_items_usagehelp = S("To open or close the trapdoor, rightclick it or send a redstone signal to it."),
wield_image = "mcl_bamboo_trapdoor_side.png",
inventory_image = "mcl_bamboo_trapdoor_side.png",
groups = {handy = 1, axey = 1, mesecon_effector_on = 1, material_wood = 1, flammable = -1},
_mcl_hardness = 3,
_mcl_blast_resistance = 3,
sounds = mcl_sounds.node_sound_wood_defaults(),
}
mcl_doors:register_trapdoor(name, trap_def)
minetest.register_alias("bamboo_door", "mcl_bamboo:bamboo_door")
minetest.register_alias("bamboo_trapdoor", "mcl_bamboo:bamboo_trapdoor")
end
end
end
-- ------------------------------------
tiki_lamp()
bamboo_doors_original()
green_bamboo_doors()

Binary file not shown.

Before

Width:  |  Height:  |  Size: 335 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 189 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 689 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 687 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 256 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 248 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 636 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 624 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 262 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 245 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 901 B