diff --git a/craft.lua b/craft.lua new file mode 100644 index 0000000..1e52d95 --- /dev/null +++ b/craft.lua @@ -0,0 +1,181 @@ +minetest.register_craft({ + output = 'plant_blocks:brush', + recipe = { + {'basic_materials:plastic_sheet','', ''}, + {'basic_materials:steel_strip', '', ''}, + {'default:stick', '', ''}, + } +}) + +minetest.register_craft({ + output = 'plant_blocks:ruler', + recipe = { + {'default:stick','default:sword_steel', ''}, + }, + replacements = {{"default:sword_steel", "default:sword_steel"}} +}) + +minetest.register_craft({ + output = 'plant_blocks:scissors', + recipe = { + {'basic_materials:steel_strip', '', ''}, + {'basic_materials:plastic_sheet','', ''}, + } +}) + +minetest.register_craft({ + output = 'plant_blocks:triangular_stencil', + recipe = { + {'basic_materials:plastic_sheet','plant_blocks:scissors','plant_blocks:ruler'} + }, + replacements = { + {"plant_blocks:scissors", "plant_blocks:scissors"}, + {"plant_blocks:ruler", "plant_blocks:ruler"}, + } +}) + +minetest.register_craft({ + output = 'plant_blocks:floor', + recipe = { + {'basic_materials:cement_block','plant_blocks:brush', 'dye:grey'}, + }, + replacements = {{"plant_blocks:brush", "plant_blocks:brush"}} +}) + +minetest.register_craft({ + output = 'plant_blocks:yellow_black_floor', + recipe = { + {'dye:black','dye:yellow', ''}, + {'basic_materials:cement_block', 'plant_blocks:brush', ''}, + {'', '', ''}, + }, + replacements = {{"plant_blocks:brush", "plant_blocks:brush"}} +}) + +minetest.register_craft({ + output = 'plant_blocks:yellow_black_line_floor', + recipe = { + {'dye:black','dye:yellow', 'plant_blocks:ruler'}, + {'plant_blocks:floor', 'plant_blocks:brush', ''}, + {'', '', ''}, + }, + replacements = { + {"plant_blocks:brush", "plant_blocks:brush"}, + {"plant_blocks:ruler", "plant_blocks:ruler"} + } +}) + +minetest.register_craft({ + output = 'plant_blocks:yellow_black_line_corner_floor', + recipe = { + {'dye:black','dye:yellow', 'plant_blocks:ruler'}, + {'plant_blocks:floor', 'plant_blocks:brush', 'plant_blocks:ruler'}, + {'', '', ''}, + }, + replacements = { + {"plant_blocks:brush", "plant_blocks:brush"}, + {"plant_blocks:ruler", "plant_blocks:ruler"}, + {"plant_blocks:ruler", "plant_blocks:ruler"} + } +}) + +minetest.register_craft({ + output = 'plant_blocks:forklift_floor_sign', + recipe = { + {'dye:black','plant_blocks:triangular_stencil', 'dye:yellow'}, + {'', 'plant_blocks:floor', ''}, + {'plant_blocks:brush', '', ''}, + }, + replacements = { + {"plant_blocks:brush", "plant_blocks:brush"}, + {"plant_blocks:triangular_stencil", "plant_blocks:triangular_stencil"}, + } +}) + +minetest.register_craft({ + output = 'plant_blocks:wall_sign_attention_forklift_operating', + recipe = { + {'dye:black','plant_blocks:triangular_stencil', 'dye:yellow'}, + {'plant_blocks:brush', 'basic_materials:plastic_sheet', 'plant_blocks:scissors'}, + }, + replacements = { + {"plant_blocks:brush", "plant_blocks:brush"}, + {"plant_blocks:triangular_stencil", "plant_blocks:triangular_stencil"}, + {"plant_blocks:scissors", "plant_blocks:scissors"}, + } +}) + +minetest.register_craft({ + output = 'plant_blocks:yellow_line_floor', + recipe = { + {'','dye:yellow', 'plant_blocks:ruler'}, + {'plant_blocks:floor', 'plant_blocks:brush', ''}, + {'', '', ''}, + }, + replacements = { + {"plant_blocks:brush", "plant_blocks:brush"}, + {"plant_blocks:ruler", "plant_blocks:ruler"} + } +}) + +minetest.register_craft({ + output = 'plant_blocks:yellow_line_corner_floor', + recipe = { + {'','dye:yellow', 'plant_blocks:ruler'}, + {'plant_blocks:floor', 'plant_blocks:brush', 'plant_blocks:ruler'}, + {'', '', ''}, + }, + replacements = { + {"plant_blocks:brush", "plant_blocks:brush"}, + {"plant_blocks:ruler", "plant_blocks:ruler"}, + {"plant_blocks:ruler", "plant_blocks:ruler"} + } +}) + +minetest.register_craft({ + output = 'plant_blocks:e05', + recipe = { + {'dye:green','plant_blocks:ruler', 'plant_blocks:brush'}, + {'default:sign_wall_wood', '', ''}, + {'', '', ''}, + }, + replacements = { + {"plant_blocks:brush", "plant_blocks:brush"}, + {"plant_blocks:ruler", "plant_blocks:ruler"}, + } +}) + +minetest.register_craft({ + output = 'plant_blocks:e06', + recipe = { + {'plant_blocks:e05','', ''}, + }, + replacements = { + {"plant_blocks:brush", "plant_blocks:brush"}, + {"plant_blocks:ruler", "plant_blocks:ruler"}, + } +}) + +minetest.register_craft({ + output = 'plant_blocks:e07', + recipe = { + {'dye:green','plant_blocks:ruler', ''}, + {'default:sign_wall_wood', 'plant_blocks:brush', ''}, + {'', '', ''}, + }, + replacements = { + {"plant_blocks:brush", "plant_blocks:brush"}, + {"plant_blocks:ruler", "plant_blocks:ruler"}, + } +}) + +minetest.register_craft({ + output = 'plant_blocks:e08', + recipe = { + {'plant_blocks:e07','', ''}, + }, + replacements = { + {"plant_blocks:brush", "plant_blocks:brush"}, + {"plant_blocks:ruler", "plant_blocks:ruler"}, + } +}) diff --git a/init.lua b/init.lua index f01a482..f93a38d 100644 --- a/init.lua +++ b/init.lua @@ -1 +1,2 @@ -dofile(minetest.get_modpath("plant_blocks") .. "/industrial_floor.lua") \ No newline at end of file +dofile(minetest.get_modpath("plant_blocks") .. "/nodes.lua") +dofile(minetest.get_modpath("plant_blocks") .. "/craft.lua") diff --git a/locale/plant_blocks.ru.tr b/locale/plant_blocks.ru.tr index 674f953..ecf75a5 100644 --- a/locale/plant_blocks.ru.tr +++ b/locale/plant_blocks.ru.tr @@ -12,4 +12,5 @@ Scissors=Ножницы Industrial floor with yellow corner line=Промышленный пол с желтой угловой линией Industrial with yellow line floor=Промышленный пол с желтой линией Direction to the emergency exit down right=Направление к эвакуационному выходу направо вниз -Direction to the emergency exit to the right up=Направление к эвакуационному выходу направо вверх \ No newline at end of file +Direction to the emergency exit to the right up=Направление к эвакуационному выходу направо вверх +Direction to the emergency exit left up=Направление к эвакуационному выходу налево вверх diff --git a/industrial_floor.lua b/nodes.lua similarity index 64% rename from industrial_floor.lua rename to nodes.lua index 143e8a5..d42e595 100644 --- a/industrial_floor.lua +++ b/nodes.lua @@ -6,60 +6,24 @@ minetest.register_craftitem("plant_blocks:brush", { inventory_image = "brush.png" }) -minetest.register_craft({ - output = 'plant_blocks:brush', - recipe = { - {'basic_materials:plastic_sheet','', ''}, - {'basic_materials:steel_strip', '', ''}, - {'default:stick', '', ''}, - } -}) - --plant_blocks:ruler minetest.register_craftitem("plant_blocks:ruler", { description = S("Ruler"), inventory_image = "ruler.png" }) -minetest.register_craft({ - output = 'plant_blocks:ruler', - recipe = { - {'default:stick','default:sword_steel', ''}, - }, - replacements = {{"default:sword_steel", "default:sword_steel"}} -}) - --plant_blocks:scissors minetest.register_craftitem("plant_blocks:scissors", { description = S("Scissors"), inventory_image = "scissors.png" }) -minetest.register_craft({ - output = 'plant_blocks:scissors', - recipe = { - {'basic_materials:steel_strip', '', ''}, - {'basic_materials:plastic_sheet','', ''}, - } -}) - --plant_blocks:triangular_stencil Треугольный трафарет minetest.register_craftitem("plant_blocks:triangular_stencil", { description = S("Triangular_stencil"), inventory_image = "triangular_stencil.png" }) -minetest.register_craft({ - output = 'plant_blocks:triangular_stencil', - recipe = { - {'basic_materials:plastic_sheet','plant_blocks:scissors','plant_blocks:ruler'} - }, - replacements = { - {"plant_blocks:scissors", "plant_blocks:scissors"}, - {"plant_blocks:ruler", "plant_blocks:ruler"}, - } -}) - --[[*******************************************************************]] --plant_blocks:industrial_floor @@ -78,14 +42,6 @@ minetest.register_node("plant_blocks:floor", { sounds = default.node_sound_stone_defaults(), }) -minetest.register_craft({ - output = 'plant_blocks:floor', - recipe = { - {'basic_materials:cement_block','plant_blocks:brush', 'dye:grey'}, - }, - replacements = {{"plant_blocks:brush", "plant_blocks:brush"}} -}) - --plant_blocks:yellow_black_floor minetest.register_node("plant_blocks:yellow_black_floor", { description = S("Industrial black and yellow floor"), @@ -102,16 +58,6 @@ minetest.register_node("plant_blocks:yellow_black_floor", { sounds = default.node_sound_stone_defaults(), }) -minetest.register_craft({ - output = 'plant_blocks:yellow_black_floor', - recipe = { - {'dye:black','dye:yellow', ''}, - {'basic_materials:cement_block', 'plant_blocks:brush', ''}, - {'', '', ''}, - }, - replacements = {{"plant_blocks:brush", "plant_blocks:brush"}} -}) - --plant_blocks:yellow_black_line_floor minetest.register_node("plant_blocks:yellow_black_line_floor", { description = S("Industrial with black and yellow line floor"), @@ -130,19 +76,6 @@ minetest.register_node("plant_blocks:yellow_black_line_floor", { sounds = default.node_sound_stone_defaults(), }) -minetest.register_craft({ - output = 'plant_blocks:yellow_black_line_floor', - recipe = { - {'dye:black','dye:yellow', 'plant_blocks:ruler'}, - {'plant_blocks:floor', 'plant_blocks:brush', ''}, - {'', '', ''}, - }, - replacements = { - {"plant_blocks:brush", "plant_blocks:brush"}, - {"plant_blocks:ruler", "plant_blocks:ruler"} - } -}) - --plant_blocks:yellow_black_line_corner_floor minetest.register_node("plant_blocks:yellow_black_line_corner_floor", { description = S("Industrial floor with black and yellow corner line"), @@ -161,20 +94,6 @@ minetest.register_node("plant_blocks:yellow_black_line_corner_floor", { sounds = default.node_sound_stone_defaults(), }) -minetest.register_craft({ - output = 'plant_blocks:yellow_black_line_corner_floor', - recipe = { - {'dye:black','dye:yellow', 'plant_blocks:ruler'}, - {'plant_blocks:floor', 'plant_blocks:brush', 'plant_blocks:ruler'}, - {'', '', ''}, - }, - replacements = { - {"plant_blocks:brush", "plant_blocks:brush"}, - {"plant_blocks:ruler", "plant_blocks:ruler"}, - {"plant_blocks:ruler", "plant_blocks:ruler"} - } -}) - --plant_blocks:industrial_forklift_sign_floor minetest.register_node("plant_blocks:forklift_floor_sign", { description = S("Industrial forklift floor sign"), @@ -193,19 +112,6 @@ minetest.register_node("plant_blocks:forklift_floor_sign", { sounds = default.node_sound_stone_defaults(), }) -minetest.register_craft({ - output = 'plant_blocks:forklift_floor_sign', - recipe = { - {'dye:black','plant_blocks:triangular_stencil', 'dye:yellow'}, - {'', 'plant_blocks:floor', ''}, - {'plant_blocks:brush', '', ''}, - }, - replacements = { - {"plant_blocks:brush", "plant_blocks:brush"}, - {"plant_blocks:triangular_stencil", "plant_blocks:triangular_stencil"}, - } -}) - --plant_blocks:wall_sign_attention_forklift_operating Настенный знак внимание работает автопогрузчик minetest.register_node("plant_blocks:wall_sign_attention_forklift_operating", { description = S("Wall sign attention to forklift operating"), @@ -254,19 +160,6 @@ minetest.register_node("plant_blocks:wall_sign_attention_forklift_operating", { groups = {crumbly=3}, }) -minetest.register_craft({ - output = 'plant_blocks:wall_sign_attention_forklift_operating', - recipe = { - {'dye:black','plant_blocks:triangular_stencil', 'dye:yellow'}, - {'plant_blocks:brush', 'basic_materials:plastic_sheet', 'plant_blocks:scissors'}, - }, - replacements = { - {"plant_blocks:brush", "plant_blocks:brush"}, - {"plant_blocks:triangular_stencil", "plant_blocks:triangular_stencil"}, - {"plant_blocks:scissors", "plant_blocks:scissors"}, - } -}) - --plant_blocks:yellow_line_floor minetest.register_node("plant_blocks:yellow_line_floor", { description = S("Industrial with yellow line floor"), @@ -285,19 +178,6 @@ minetest.register_node("plant_blocks:yellow_line_floor", { sounds = default.node_sound_stone_defaults(), }) -minetest.register_craft({ - output = 'plant_blocks:yellow_line_floor', - recipe = { - {'','dye:yellow', 'plant_blocks:ruler'}, - {'plant_blocks:floor', 'plant_blocks:brush', ''}, - {'', '', ''}, - }, - replacements = { - {"plant_blocks:brush", "plant_blocks:brush"}, - {"plant_blocks:ruler", "plant_blocks:ruler"} - } -}) - --plant_blocks:yellow_line_corner_floor minetest.register_node("plant_blocks:yellow_line_corner_floor", { description = S("Industrial floor with yellow corner line"), @@ -316,18 +196,54 @@ minetest.register_node("plant_blocks:yellow_line_corner_floor", { sounds = default.node_sound_stone_defaults(), }) -minetest.register_craft({ - output = 'plant_blocks:yellow_line_corner_floor', - recipe = { - {'','dye:yellow', 'plant_blocks:ruler'}, - {'plant_blocks:floor', 'plant_blocks:brush', 'plant_blocks:ruler'}, - {'', '', ''}, +--plant_blocks:e05 +minetest.register_node("plant_blocks:e05", { + description = S("Direction to the emergency exit to the right up"), + inventory_image = "plant_blocks_e05.png", + tiles = { + "bg_green_sign.png", + "bg_green_sign.png", + "bg_green_sign.png", + "bg_green_sign.png", + "bg_green_sign.png", + "[combine:64x60:0,0=plant_blocks_e05.png" }, - replacements = { - {"plant_blocks:brush", "plant_blocks:brush"}, - {"plant_blocks:ruler", "plant_blocks:ruler"}, - {"plant_blocks:ruler", "plant_blocks:ruler"} - } + drawtype = "nodebox", + legacy_facedir_simple = false, + paramtype2 = "facedir", + node_box = { + type = "fixed", + fixed = { + {-0.5, -0, 0.46, 0.5, 0.5, 0.5}, + }, + }, + is_ground_content = false, + groups = {crumbly=3}, +}) + +--plant_blocks:e06 +minetest.register_node("plant_blocks:e06", { + description = S("Direction to the emergency exit left up"), + inventory_image = "plant_blocks_e05.png", + tiles = { + "bg_green_sign.png", + "bg_green_sign.png", + "bg_green_sign.png", + "bg_green_sign.png", + "bg_green_sign.png", + "[combine:64x60:0,0=plant_blocks_e05.png^[transform4" + }, + drawtype = "nodebox", + legacy_facedir_simple = false, + paramtype2 = "facedir", + node_box = { + type = "fixed", + fixed = { + {-0.5, -0, 0.46, 0.5, 0.5, 0.5}, + }, + }, + is_ground_content = false, + groups = {crumbly=3}, }) --plant_blocks:e07 @@ -377,22 +293,9 @@ minetest.register_node("plant_blocks:e07", { --on_place = minetest.rotate_node, }) -minetest.register_craft({ - output = 'plant_blocks:e07', - recipe = { - {'dye:green','plant_blocks:ruler', ''}, - {'default:sign_wall_wood', 'plant_blocks:brush', ''}, - {'', '', ''}, - }, - replacements = { - {"plant_blocks:brush", "plant_blocks:brush"}, - {"plant_blocks:ruler", "plant_blocks:ruler"}, - } -}) - ---plant_blocks:e05 -minetest.register_node("plant_blocks:e05", { - description = S("Direction to the emergency exit to the right up"), +--plant_blocks:e06 +minetest.register_node("plant_blocks:e08", { + description = S("Direction to the emergency exit left down"), inventory_image = "plant_blocks_e05.png", tiles = { "bg_green_sign.png", @@ -400,7 +303,7 @@ minetest.register_node("plant_blocks:e05", { "bg_green_sign.png", "bg_green_sign.png", "bg_green_sign.png", - "[combine:64x60:0,0=plant_blocks_e05.png" --^[transform4 + "[combine:64x60:0,0=plant_blocks_e07.png^[transform4" }, drawtype = "nodebox", legacy_facedir_simple = false, @@ -414,16 +317,3 @@ minetest.register_node("plant_blocks:e05", { is_ground_content = false, groups = {crumbly=3}, }) - -minetest.register_craft({ - output = 'plant_blocks:e05', - recipe = { - {'dye:green','plant_blocks:ruler', 'plant_blocks:brush'}, - {'default:sign_wall_wood', '', ''}, - {'', '', ''}, - }, - replacements = { - {"plant_blocks:brush", "plant_blocks:brush"}, - {"plant_blocks:ruler", "plant_blocks:ruler"}, - } -}) \ No newline at end of file