diff --git a/brown_stone.lua b/brown_stone.lua new file mode 100644 index 0000000..b755ed3 --- /dev/null +++ b/brown_stone.lua @@ -0,0 +1,58 @@ +local stone_corners = { --Material , Description , Image , Item + { "default_cobble" , "Cobble" , "default_cobble", "default:cobble"}, + { "default_stone" , "Stone" , "default_stone", "default:stone"}, + { "default_stone_brick" , "Stone Brick" , "default_stone_brick", "default:stonebrick"}, + { "default_brick" , "brick" , "default_brick", "default:brick"}, + { "default_wood" , "Wood" , "default_wood", "default:wood"}, + { "default_pinewood" , "Pine Wood" , "default_pinewood", "default:pinewood"}, + { "default_sandstone" , "Sandstone " , "default_sandstone", "default:sandstone"}, + { "default_sandstone_brick" , "Sandstone Brick" , "default_sandstone_brick", "default:sandstonebrick"}, +} + +for i in ipairs(stone_corners) do + local mat = stone_corners[i][1] + local desc = stone_corners[i][2] + local img = stone_corners[i][3] + local item = stone_corners[i][4] + +minetest.register_node("mycorners:brown_stone_"..mat.."_corner", { + description = "Brown Stone "..desc.." Corner", + drawtype = "normal", + paramtype = "light", + tiles = { + img..".png", + img..".png", + img..".png", + img..".png^corners_stone6.png", + img..".png", + img..".png^corners_stone5.png", + }, + paramtype = "light", + paramtype2 = "facedir", + groups = {cracky = 2}, + +}) +minetest.register_craft({ + output = "mycorners:brown_stone_"..mat.."_corner 1", + recipe = { + {item,"mycorners:brown_stone_corner_block",""}, + {"mycorners:brown_stone_corner_block","",""}, + {"","",""}, + } +}) +end + +--stone corner +minetest.register_craftitem("mycorners:brown_stone_corner_block", { + description = "Brown Stone Corner Block", + inventory_image = "corners_stone5.png", +}) + +minetest.register_craft({ + output = "mycorners:brown_stone_corner_block 16", + recipe = { + {"mycorners:stone_corner_block","",""}, + {"dye:brown","",""}, + {"","",""}, + } +}) diff --git a/depends.txt b/depends.txt index 4ad96d5..2717bef 100644 --- a/depends.txt +++ b/depends.txt @@ -1 +1,2 @@ default +dye diff --git a/init.lua b/init.lua index 93bfe98..b56c465 100644 --- a/init.lua +++ b/init.lua @@ -1,6 +1,8 @@ -- Stone Corners dofile(minetest.get_modpath("mycorners").."/stone.lua") +dofile(minetest.get_modpath("mycorners").."/light_stone.lua") +dofile(minetest.get_modpath("mycorners").."/brown_stone.lua") -- Brick Corners dofile(minetest.get_modpath("mycorners").."/stone_brick.lua") diff --git a/light_stone.lua b/light_stone.lua new file mode 100644 index 0000000..ef6dff4 --- /dev/null +++ b/light_stone.lua @@ -0,0 +1,58 @@ +local stone_corners = { --Material , Description , Image , Item + { "default_cobble" , "Cobble" , "default_cobble", "default:cobble"}, + { "default_stone" , "Stone" , "default_stone", "default:stone"}, + { "default_stone_brick" , "Stone Brick" , "default_stone_brick", "default:stonebrick"}, + { "default_brick" , "brick" , "default_brick", "default:brick"}, + { "default_wood" , "Wood" , "default_wood", "default:wood"}, + { "default_pinewood" , "Pine Wood" , "default_pinewood", "default:pinewood"}, + { "default_sandstone" , "Sandstone " , "default_sandstone", "default:sandstone"}, + { "default_sandstone_brick" , "Sandstone Brick" , "default_sandstone_brick", "default:sandstonebrick"}, +} + +for i in ipairs(stone_corners) do + local mat = stone_corners[i][1] + local desc = stone_corners[i][2] + local img = stone_corners[i][3] + local item = stone_corners[i][4] + +minetest.register_node("mycorners:light_stone_"..mat.."_corner", { + description = "Stone "..desc.." Corner", + drawtype = "normal", + paramtype = "light", + tiles = { + img..".png", + img..".png", + img..".png", + img..".png^corners_stone4.png", + img..".png", + img..".png^corners_stone3.png", + }, + paramtype = "light", + paramtype2 = "facedir", + groups = {cracky = 2}, + +}) +minetest.register_craft({ + output = "mycorners:light_stone_"..mat.."_corner 1", + recipe = { + {item,"mycorners:light_stone_corner_block",""}, + {"mycorners:light_stone_corner_block","",""}, + {"","",""}, + } +}) +end + +--stone corner +minetest.register_craftitem("mycorners:light_stone_corner_block", { + description = "Light Stone Corner Block", + inventory_image = "corners_stone3.png", +}) + +minetest.register_craft({ + output = "mycorners:light_stone_corner_block 16", + recipe = { + {"mycorners:stone_corner_block","",""}, + {"dye:yellow","",""}, + {"","",""}, + } +}) diff --git a/light_stone.lua~ b/light_stone.lua~ new file mode 100644 index 0000000..2ba2f76 --- /dev/null +++ b/light_stone.lua~ @@ -0,0 +1,34 @@ +local stone_corners = { --Material , Description , Image + { "default_cobble" , "Cobble" , "default_cobble"}, + { "default_stone" , "Stone" , "default_stone"}, + { "default_stone_brick" , "Stone Brick" , "default_stone_brick"}, + { "default_brick" , "brick" , "default_brick"}, +-- { "default_wood" , "Wood" , "default_wood"}, +-- { "default_pinewood" , "Pine Wood" , "default_pinewood"}, +-- { "default_sandstone" , "Sandstone " , "default_sandstone"}, +-- { "default_sandstone_brick" , "Sandstone Brick" , "default_sandstone_brick"}, +} + +for i in ipairs(stone_corners) do + local mat = stone_corners[i][1] + local desc = stone_corners[i][2] + local img = stone_corners[i][3] + +minetest.register_node("mycorners:stone_"..mat.."_corner", { + description = "Stone "..desc.." Corner", + drawtype = "normal", + paramtype = "light", + tiles = { + img..".png", + img..".png", + img..".png", + img..".png^corners_stone2.png", + img..".png", + img..".png^corners_stone1.png", + }, + paramtype = "light", + paramtype2 = "facedir", + groups = {cracky = 2}, + +}) +end diff --git a/light_stone_brick.lua b/light_stone_brick.lua index a60855f..6fa4142 100644 --- a/light_stone_brick.lua +++ b/light_stone_brick.lua @@ -3,10 +3,10 @@ local wood_corners = { --Material , Description , Image , Item { "default_stone" , "Stone" , "default_stone", "default:stone"}, { "default_stone_brick" , "Stone Brick" , "default_stone_brick", "default:stonebrick"}, { "default_brick" , "brick" , "default_brick", "default:brick"}, --- { "default_wood" , "Wood" , "default_wood", "default:wood"}, --- { "default_pinewood" , "Pine Wood" , "default_pinewood", "default:pinewood"}, + { "default_wood" , "Wood" , "default_wood", "default:wood"}, + { "default_pinewood" , "Pine Wood" , "default_pinewood", "default:pinewood"}, { "default_sandstone" , "Sandstone " , "default_sandstone", "default:sandstone"}, --- { "default_sandstone_brick" , "Sandstone Brick" , "default_sandstone_brick", "default:sandstonebrick"}, + { "default_sandstone_brick" , "Sandstone Brick" , "default_sandstone_brick", "default:sandstonebrick"}, } for i in ipairs(wood_corners) do diff --git a/stone.lua b/stone.lua index 2ba2f76..385ad12 100644 --- a/stone.lua +++ b/stone.lua @@ -1,18 +1,19 @@ -local stone_corners = { --Material , Description , Image - { "default_cobble" , "Cobble" , "default_cobble"}, - { "default_stone" , "Stone" , "default_stone"}, - { "default_stone_brick" , "Stone Brick" , "default_stone_brick"}, - { "default_brick" , "brick" , "default_brick"}, --- { "default_wood" , "Wood" , "default_wood"}, --- { "default_pinewood" , "Pine Wood" , "default_pinewood"}, --- { "default_sandstone" , "Sandstone " , "default_sandstone"}, --- { "default_sandstone_brick" , "Sandstone Brick" , "default_sandstone_brick"}, +local stone_corners = { --Material , Description , Image , Item + { "default_cobble" , "Cobble" , "default_cobble", "default:cobble"}, + { "default_stone" , "Stone" , "default_stone", "default:stone"}, + { "default_stone_brick" , "Stone Brick" , "default_stone_brick", "default:stonebrick"}, + { "default_brick" , "brick" , "default_brick", "default:brick"}, + { "default_wood" , "Wood" , "default_wood", "default:wood"}, + { "default_pinewood" , "Pine Wood" , "default_pinewood", "default:pinewood"}, + { "default_sandstone" , "Sandstone " , "default_sandstone", "default:sandstone"}, + { "default_sandstone_brick" , "Sandstone Brick" , "default_sandstone_brick", "default:sandstonebrick"}, } for i in ipairs(stone_corners) do local mat = stone_corners[i][1] local desc = stone_corners[i][2] local img = stone_corners[i][3] + local item = stone_corners[i][4] minetest.register_node("mycorners:stone_"..mat.."_corner", { description = "Stone "..desc.." Corner", @@ -31,4 +32,28 @@ minetest.register_node("mycorners:stone_"..mat.."_corner", { groups = {cracky = 2}, }) + +minetest.register_craft({ + output = "mycorners:stone_"..mat.."_corner 1", + recipe = { + {item,"mycorners:stone_corner_block",""}, + {"mycorners:stone_corner_block","",""}, + {"","",""}, + } +}) end + +--stone corner +minetest.register_craftitem("mycorners:stone_corner_block", { + description = "Stone Corner Block", + inventory_image = "corners_stone1.png", +}) + +minetest.register_craft({ + output = "mycorners:stone_corner_block 16", + recipe = { + {"default:cobble","",""}, + {"default:cobble","default:cobble",""}, + {"default:cobble","",""}, + } +}) diff --git a/textures/corners_stone1.png b/textures/corners_stone1.png index c469f96..62c0b6c 100644 Binary files a/textures/corners_stone1.png and b/textures/corners_stone1.png differ diff --git a/textures/corners_stone2.png b/textures/corners_stone2.png index 26cddd2..4366698 100644 Binary files a/textures/corners_stone2.png and b/textures/corners_stone2.png differ diff --git a/textures/corners_stone3.png b/textures/corners_stone3.png new file mode 100644 index 0000000..c469f96 Binary files /dev/null and b/textures/corners_stone3.png differ diff --git a/textures/corners_stone4.png b/textures/corners_stone4.png new file mode 100644 index 0000000..26cddd2 Binary files /dev/null and b/textures/corners_stone4.png differ diff --git a/textures/corners_stone5.png b/textures/corners_stone5.png new file mode 100644 index 0000000..afe11fe Binary files /dev/null and b/textures/corners_stone5.png differ diff --git a/textures/corners_stone6.png b/textures/corners_stone6.png new file mode 100644 index 0000000..d3979ce Binary files /dev/null and b/textures/corners_stone6.png differ