/ bjvxlx_bronze / building.lua
building.lua
1 local mod = bjvxlx.bronze 2 local S = mod.translate 3 4 mcl_doors:register_door('bjvxlx_bronze:bronze_door', { 5 description = S("Bronze Door"), 6 _doc_items_longdesc = S(table.concat({ 7 "Bronze doors are 2-block-high barriers", 8 "which can only be opened or closed by a redstone signal,", 9 "but not by hand.", 10 }, ' ')), 11 _doc_items_usagehelp = S(table.concat({ 12 "To open or close a bronze door, supply its lower half", 13 "with a redstone signal." 14 }, ' ')), 15 inventory_image = "bjvxlx_bronze_door.png", 16 groups = {pickaxey = 1, mesecon_effector_on = 1}, 17 _mcl_hardness = 5, 18 _mcl_blast_resistance = 5, 19 tiles_bottom = "bjvxlx_bronze_door_lower.png", 20 tiles_top = "bjvxlx_bronze_door_upper.png", 21 sounds = mcl_sounds.node_sound_metal_defaults(), 22 sound_open = "doors_steel_door_open", 23 sound_close = "doors_steel_door_close", 24 only_redstone_can_open = true 25 }) 26 minetest.register_craft({ 27 type = 'shaped', 28 output = "bjvxlx_bronze:bronze_door 3", 29 recipe = { 30 {'bjvxlx_bronze:bronze_ingot', 'bjvxlx_bronze:bronze_ingot'}, 31 {'bjvxlx_bronze:bronze_ingot', 'bjvxlx_bronze:bronze_ingot'}, 32 {'bjvxlx_bronze:bronze_ingot', 'bjvxlx_bronze:bronze_ingot'} 33 } 34 }) 35 mcl_doors:register_trapdoor('bjvxlx_bronze:bronze_trapdoor', { 36 description = S("Bronze Trapdoor"), 37 _doc_items_longdesc = S(table.concat({ 38 "Bronze trapdoors are horizontal barriers", 39 "which can only be opened and closed by redstone signals,", 40 "but not by hand. They occupy the upper or lower part", 41 "of a block, depending on how they have been placed.", 42 "When open, they can be climbed like a ladder." 43 }, ' ')), 44 tile_front = "bjvxlx_bronze_trapdoor.png", 45 tile_side = "bjvxlx_bronze_trapdoor_side.png", 46 wield_image = "bjvxlx_bronze_trapdoor.png", 47 groups = {pickaxey = 1, mesecon_effector_on = 1}, 48 _mcl_hardness = 5, 49 _mcl_blast_resistance = 5, 50 sounds = mcl_sounds.node_sound_metal_defaults(), 51 sound_open = "doors_steel_door_open", 52 sound_close = "doors_steel_door_close", 53 only_redstone_can_open = true 54 }) 55 minetest.register_craft({ 56 type = 'shaped', 57 output = "bjvxlx_bronze:bronze_trapdoor", 58 recipe = { 59 {'bjvxlx_bronze:bronze_ingot', 'bjvxlx_bronze:bronze_ingot'}, 60 {'bjvxlx_bronze:bronze_ingot', 'bjvxlx_bronze:bronze_ingot'} 61 } 62 }) 63 64 mcl_stairs.register_slab('bronze_block', 'bjvxlx_bronze:bronze_block', 65 {pickaxey = 2}, 66 {'bjvxlx_bronze_block.png', 'bjvxlx_bronze_block.png', 67 'bjvxlx_bronze_slab.png'}, 68 S("Slab of Bronze"), 69 mcl_sounds.node_sound_metal_defaults(), nil, nil, 70 S("Double Slab of Bronze")) 71 mcl_stairs.register_stair('bronze_block', 'bjvxlx_bronze:bronze_block', 72 {pickaxey = 2}, 73 {'bjvxlx_bronze_slab.png', 'bjvxlx_bronze_block.png', 74 'bjvxlx_bronze_block.png', 'bjvxlx_bronze_block.png', 75 'bjvxlx_bronze_block.png', 'bjvxlx_bronze_slab.png'}, 76 S("Stairs of Bronze"), 77 mcl_sounds.node_sound_metal_defaults(), 6, nil, 78 "woodlike") 79 80 xpanes.register_pane('bronze_bar', { 81 description = S("Bronze Bars"), 82 _doc_items_longdesc = S( 83 "Bronze bars neatly connect to their neighbors as you build them." 84 ), 85 textures = { 86 "bjvxlx_pane_bronze.png", 87 "bjvxlx_pane_bronze.png", 88 "bjvxlx_pane_top_bronze.png" 89 }, 90 inventory_image = "bjvxlx_pane_bronze.png", 91 wield_image = "bjvxlx_pane_bronze.png", 92 groups = {pickaxey = 1}, 93 sounds = mcl_sounds.node_sound_metal_defaults(), 94 use_texture_alpha = 95 minetest.features.use_texture_alpha_string_modes and 'clip' or true, 96 recipe = { 97 {'bjvxlx_bronze:bronze_ingot', 'bjvxlx_bronze:bronze_ingot', 98 'bjvxlx_bronze:bronze_ingot'}, 99 {'bjvxlx_bronze:bronze_ingot', 'bjvxlx_bronze:bronze_ingot', 100 'bjvxlx_bronze:bronze_ingot'} 101 }, 102 _mcl_blast_resistance = 6, 103 _mcl_hardness = 5 104 })