2017-02-22 02:05:37 +02:00
|
|
|
local anvildef = {
|
2017-11-27 08:57:02 +02:00
|
|
|
groups = {pickaxey=1, falling_node=1, crush_after_fall=1, deco_block=1, anvil=1},
|
2017-07-14 20:54:25 +03:00
|
|
|
tiles = {"mcl_anvils_anvil_top_damaged_0.png^[transformR90", "mcl_anvils_anvil_base.png", "mcl_anvils_anvil_side.png"},
|
2017-02-22 02:05:37 +02:00
|
|
|
paramtype = "light",
|
|
|
|
sunlight_propagates = true,
|
|
|
|
is_ground_content = false,
|
|
|
|
paramtype2 = "facedir",
|
|
|
|
drawtype = "nodebox",
|
|
|
|
node_box = {
|
|
|
|
type = "fixed",
|
|
|
|
fixed = {
|
2018-01-31 20:23:37 +02:00
|
|
|
{-8/16, 2/16, -5/16, 8/16, 8/16, 5/16}, -- top
|
|
|
|
{-6/16, -4/16, -1/16, 6/16, 5/16, 1/16}, -- middle
|
|
|
|
{-8/16, -8/16, -5/16, 8/16, -4/16, 5/16}, -- base
|
2017-02-22 02:05:37 +02:00
|
|
|
}
|
|
|
|
},
|
|
|
|
sounds = mcl_sounds.node_sound_metal_defaults(),
|
2017-02-22 16:40:22 +02:00
|
|
|
_mcl_blast_resistance = 6000,
|
2017-02-27 02:13:03 +02:00
|
|
|
_mcl_hardness = 5,
|
2017-02-22 02:05:37 +02:00
|
|
|
}
|
2017-12-05 15:09:39 +02:00
|
|
|
if minetest.get_modpath("screwdriver") then
|
|
|
|
anvildef.on_rotate = screwdriver.rotate_simple
|
|
|
|
end
|
2017-02-22 02:05:37 +02:00
|
|
|
|
|
|
|
local anvildef0 = table.copy(anvildef)
|
|
|
|
anvildef0.description = "Anvil"
|
|
|
|
|
|
|
|
local anvildef1 = table.copy(anvildef)
|
|
|
|
anvildef1.description = "Slightly Damaged Anvil"
|
|
|
|
anvildef1.groups.not_in_creative_inventory = 1
|
2017-03-02 20:53:53 +02:00
|
|
|
anvildef1._doc_items_create_entry = false
|
2017-07-14 20:54:25 +03:00
|
|
|
anvildef1.tiles = {"mcl_anvils_anvil_top_damaged_1.png^[transformR90", "mcl_anvils_anvil_base.png", "mcl_anvils_anvil_side.png"}
|
2017-02-22 02:05:37 +02:00
|
|
|
|
|
|
|
local anvildef2 = table.copy(anvildef)
|
|
|
|
anvildef2.description = "Very Damaged Anvil"
|
|
|
|
anvildef2.groups.not_in_creative_inventory = 1
|
2017-03-02 20:53:53 +02:00
|
|
|
anvildef2._doc_items_create_entry = false
|
2017-07-14 20:54:25 +03:00
|
|
|
anvildef2.tiles = {"mcl_anvils_anvil_top_damaged_2.png^[transformR90", "mcl_anvils_anvil_base.png", "mcl_anvils_anvil_side.png"}
|
2017-02-22 02:05:37 +02:00
|
|
|
|
|
|
|
minetest.register_node("mcl_anvils:anvil", anvildef0)
|
|
|
|
minetest.register_node("mcl_anvils:anvil_damage_1", anvildef1)
|
|
|
|
minetest.register_node("mcl_anvils:anvil_damage_2", anvildef2)
|
|
|
|
|
|
|
|
minetest.register_craft({
|
|
|
|
output = "mcl_anvils:anvil",
|
|
|
|
recipe = {
|
|
|
|
{ "mcl_core:ironblock", "mcl_core:ironblock", "mcl_core:ironblock" },
|
|
|
|
{ "", "mcl_core:iron_ingot", "" },
|
|
|
|
{ "mcl_core:iron_ingot", "mcl_core:iron_ingot", "mcl_core:iron_ingot" },
|
|
|
|
}
|
|
|
|
})
|
2017-02-22 03:38:41 +02:00
|
|
|
|
|
|
|
dofile(minetest.get_modpath(minetest.get_current_modname()).."/falling_anvil.lua")
|