Cleaned Code

Modified screenshot
This commit is contained in:
DonBatman 2016-04-02 19:40:19 -07:00
parent e19b673036
commit 600c603862
4 changed files with 230 additions and 156 deletions

View File

@ -1,5 +1,6 @@
local USES = 200 local USES = 200
local mode = {} local mode = {}
local function parti(pos) local function parti(pos)
minetest.add_particlespawner(25, 0.3, minetest.add_particlespawner(25, 0.3,
pos, pos, pos, pos,
@ -9,166 +10,215 @@ local function parti(pos)
0.2, 2, 0.2, 2,
true, "mychisel_parti.png") true, "mychisel_parti.png")
end end
mode = "1" mode = "1"
minetest.register_tool( "mychisel:chisel",{ minetest.register_tool( "mychisel:chisel",{
description = "Chisel", description = "Chisel",
inventory_image = "mychisel_chisel.png", inventory_image = "mychisel_chisel.png",
wield_image = "mychisel_chisel.png", wield_image = "mychisel_chisel.png",
on_use = function(itemstack, user, pointed_thing)
if pointed_thing.type ~= "node" then on_use = function(itemstack, user, pointed_thing)
return
if pointed_thing.type ~= "node" then
return
end
local pos = pointed_thing.under
local node = minetest.get_node(pos)
local default_material = {
{"default:cobble", "default_cobble", "Cobble"},
{"default:sandstone","default_sandstone", "Sandstone"},
{"default:clay","default_clay", "Clay"},
{"default:coalblock","default_coal_block", "Coal Block"},
{"default:stone","default_stone", "Stone"},
{"default:desert_stone","default_desert_stone", "Desert Stone"},
{"default:wood","default_wood", "Wood"},
{"default:acacia_wood","default_acacia_wood", "Acacia Wood"},
{"default:aspen_wood","default_aspen_wood", "Aspen Wood"},
{"default:pine_wood","default_pine_wood", "Pine Wood"},
{"default:desert_cobble","default_desert_cobble", "Desert Cobble"},
{"default:junglewood","default_junglewood", "Jungle Wood"},
{"default:sandstonebrick","default_sandstone_brick", "Sandstone Brick"},
{"default:stonebrick","default_stone_brick", "Stone Brick"},
{"default:desert_stonebrick","default_desert_stone_brick", "Desert Stone Brick"},
}
for i in ipairs (default_material) do
local item = default_material [i][1]
local mat = default_material [i][2]
local desc = default_material [i][3]
if pointed_thing.type ~= "node" then
return
end
if minetest.is_protected(pos, user:get_player_name()) then
minetest.record_protection_violation(pos, user:get_player_name())
return
end
if mode == "1" then
if node.name == item then
minetest.set_node(pos,{name = "mychisel:chiseled_"..mat.."1", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:chiseled_"..mat.."1" then
minetest.set_node(pos,{name = "mychisel:chiseled_"..mat.."2", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:chiseled_"..mat.."2" then
minetest.set_node(pos,{name = "mychisel:chiseled_"..mat.."3", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:chiseled_"..mat.."3" then
minetest.set_node(pos,{name = "mychisel:chiseled_"..mat.."4", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
end
if mode == "2" then
if node.name == item then
minetest.set_node(pos,{name = "mychisel:horizontal_"..mat.."1", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:horizontal_"..mat.."1" then
minetest.set_node(pos,{name = "mychisel:horizontal_"..mat.."2", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:horizontal_"..mat.."2" then
minetest.set_node(pos,{name = "mychisel:horizontal_"..mat.."3", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:horizontal_"..mat.."3" then
minetest.set_node(pos,{name = "mychisel:horizontal_"..mat.."4", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
end
if mode == "3" then
if node.name == item then
minetest.set_node(pos,{name = "mychisel:vertical_"..mat.."1", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:vertical_"..mat.."1" then
minetest.set_node(pos,{name = "mychisel:vertical_"..mat.."2", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:vertical_"..mat.."2" then
minetest.set_node(pos,{name = "mychisel:vertical_"..mat.."3", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:vertical_"..mat.."3" then
minetest.set_node(pos,{name = "mychisel:vertical_"..mat.."4", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
end
if mode == "4" then
if node.name == item then
minetest.set_node(pos,{name = "mychisel:cross_"..mat.."1", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:cross_"..mat.."1" then
minetest.set_node(pos,{name = "mychisel:cross_"..mat.."2", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:cross_"..mat.."2" then
minetest.set_node(pos,{name = "mychisel:cross_"..mat.."3", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:cross_"..mat.."3" then
minetest.set_node(pos,{name = "mychisel:cross_"..mat.."4", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
end
if mode == "5" then
if node.name == item then
minetest.set_node(pos,{name = "mychisel:square_"..mat.."1", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:square_"..mat.."1" then
minetest.set_node(pos,{name = "mychisel:square_"..mat.."2", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:square_"..mat.."2" then
minetest.set_node(pos,{name = "mychisel:square_"..mat.."3", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:square_"..mat.."3" then
minetest.set_node(pos,{name = "mychisel:square_"..mat.."4", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
end
end end
local pos = pointed_thing.under
local node = minetest.get_node(pos) if not minetest.setting_getbool("creative_mode") then
local default_material = { itemstack:add_wear(65535 / (USES - 1))
{"default:cobble", "default_cobble", "Cobble"},
{"default:sandstone","default_sandstone", "Sandstone"},
{"default:clay","default_clay", "Clay"},
{"default:coalblock","default_coal_block", "Coal Block"},
{"default:stone","default_stone", "Stone"},
{"default:desert_stone","default_desert_stone", "Desert Stone"},
{"default:wood","default_wood", "Wood"},
{"default:acacia_wood","default_acacia_wood", "Acacia Wood"},
{"default:aspen_wood","default_aspen_wood", "Aspen Wood"},
{"default:pine_wood","default_pine_wood", "Pine Wood"},
{"default:desert_cobble","default_desert_cobble", "Desert Cobble"},
{"default:junglewood","default_junglewood", "Jungle Wood"},
{"default:sandstonebrick","default_sandstone_brick", "Sandstone Brick"},
{"default:stonebrick","default_stone_brick", "Stone Brick"},
{"default:desert_stonebrick","default_desert_stone_brick", "Desert Stone Brick"},
}
for i in ipairs (default_material) do
local item = default_material [i][1]
local mat = default_material [i][2]
local desc = default_material [i][3]
if pointed_thing.type ~= "node" then
return
end
if minetest.is_protected(pos, user:get_player_name()) then
minetest.record_protection_violation(pos, user:get_player_name())
return
end
if mode == "1" then
if node.name == item then
minetest.set_node(pos,{name = "mychisel:chiseled_"..mat.."1", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end end
if node.name == "mychisel:chiseled_"..mat.."1" then
minetest.set_node(pos,{name = "mychisel:chiseled_"..mat.."2", param2=minetest.dir_to_facedir(user:get_look_dir())}) return itemstack
parti(pos)
end end,
if node.name == "mychisel:chiseled_"..mat.."2" then
minetest.set_node(pos,{name = "mychisel:chiseled_"..mat.."3", param2=minetest.dir_to_facedir(user:get_look_dir())}) on_place = function(itemstack, user, pointed_thing)
parti(pos)
end local usr = user:get_player_name()
if node.name == "mychisel:chiseled_"..mat.."3" then
minetest.set_node(pos,{name = "mychisel:chiseled_"..mat.."4", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
end
if mode == "2" then
if node.name == item then
minetest.set_node(pos,{name = "mychisel:horizontal_"..mat.."1", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:horizontal_"..mat.."1" then
minetest.set_node(pos,{name = "mychisel:horizontal_"..mat.."2", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:horizontal_"..mat.."2" then
minetest.set_node(pos,{name = "mychisel:horizontal_"..mat.."3", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:horizontal_"..mat.."3" then
minetest.set_node(pos,{name = "mychisel:horizontal_"..mat.."4", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
end
if mode == "3" then
if node.name == item then
minetest.set_node(pos,{name = "mychisel:vertical_"..mat.."1", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:vertical_"..mat.."1" then
minetest.set_node(pos,{name = "mychisel:vertical_"..mat.."2", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:vertical_"..mat.."2" then
minetest.set_node(pos,{name = "mychisel:vertical_"..mat.."3", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:vertical_"..mat.."3" then
minetest.set_node(pos,{name = "mychisel:vertical_"..mat.."4", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
end
if mode == "4" then
if node.name == item then
minetest.set_node(pos,{name = "mychisel:cross_"..mat.."1", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:cross_"..mat.."1" then
minetest.set_node(pos,{name = "mychisel:cross_"..mat.."2", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:cross_"..mat.."2" then
minetest.set_node(pos,{name = "mychisel:cross_"..mat.."3", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:cross_"..mat.."3" then
minetest.set_node(pos,{name = "mychisel:cross_"..mat.."4", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
end
if mode == "5" then
if node.name == item then
minetest.set_node(pos,{name = "mychisel:square_"..mat.."1", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:square_"..mat.."1" then
minetest.set_node(pos,{name = "mychisel:square_"..mat.."2", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:square_"..mat.."2" then
minetest.set_node(pos,{name = "mychisel:square_"..mat.."3", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
if node.name == "mychisel:square_"..mat.."3" then
minetest.set_node(pos,{name = "mychisel:square_"..mat.."4", param2=minetest.dir_to_facedir(user:get_look_dir())})
parti(pos)
end
end
end
if not minetest.setting_getbool("creative_mode") then
itemstack:add_wear(65535 / (USES - 1))
end
return itemstack
end,
on_place = function(itemstack, user, pointed_thing)
local usr = user:get_player_name()
if mode == "1" then if mode == "1" then
mode = "2" mode = "2"
minetest.chat_send_player(usr,"Horizontal Groove") minetest.chat_send_player(usr,"Horizontal Groove")
elseif mode == "2" then elseif mode == "2" then
mode = "3" mode = "3"
minetest.chat_send_player(usr,"Vertical Groove") minetest.chat_send_player(usr,"Vertical Groove")
elseif mode == "3" then elseif mode == "3" then
mode = "4" mode = "4"
minetest.chat_send_player(usr,"Cross Grooves") minetest.chat_send_player(usr,"Cross Grooves")
elseif mode == "4" then elseif mode == "4" then
mode = "5" mode = "5"
minetest.chat_send_player(usr,"Square") minetest.chat_send_player(usr,"Square")
elseif mode == "5" then elseif mode == "5" then
mode = "1" mode = "1"
minetest.chat_send_player(usr,"Chisel 4 Edges") minetest.chat_send_player(usr,"Chisel 4 Edges")
end end
if not minetest.setting_getbool("creative_mode") then
itemstack:add_wear(65535 / (USES - 1)) if not minetest.setting_getbool("creative_mode") then
end itemstack:add_wear(65535 / (USES - 1))
return itemstack end
return itemstack
end end
}) })
minetest.register_craft({ minetest.register_craft({
output = "mychisel:chisel", output = "mychisel:chisel",
recipe = { recipe = {

View File

@ -1,4 +1,6 @@
dofile(minetest.get_modpath("mychisel").."/chisel.lua") dofile(minetest.get_modpath("mychisel").."/chisel.lua")
dofile(minetest.get_modpath("mychisel").."/nodes.lua") dofile(minetest.get_modpath("mychisel").."/nodes.lua")

View File

@ -7,6 +7,7 @@ local vert1 = {
{-0.5, -0.5, -0.5, -0.1875, 0.5, 0.5}, {-0.5, -0.5, -0.5, -0.1875, 0.5, 0.5},
} }
} }
local vert2 = { local vert2 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -15,6 +16,7 @@ local vert2 = {
{-0.5, -0.5, -0.5, -0.1875, 0.5, 0.5}, {-0.5, -0.5, -0.5, -0.1875, 0.5, 0.5},
} }
} }
local vert3 = { local vert3 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -23,6 +25,7 @@ local vert3 = {
{-0.5, -0.5, -0.5, -0.1875, 0.5, 0.5}, {-0.5, -0.5, -0.5, -0.1875, 0.5, 0.5},
} }
} }
local vert4 = { local vert4 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -31,6 +34,7 @@ local vert4 = {
{-0.5, -0.5, -0.5, -0.1875, 0.5, 0.5}, {-0.5, -0.5, -0.5, -0.1875, 0.5, 0.5},
} }
} }
local hori1 = { local hori1 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -39,6 +43,7 @@ local hori1 = {
{-0.5, -0.5, -0.5, 0.5, -0.1875, 0.5}, {-0.5, -0.5, -0.5, 0.5, -0.1875, 0.5},
} }
} }
local hori2 = { local hori2 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -47,6 +52,7 @@ local hori2 = {
{-0.5, -0.5, -0.5, 0.5, -0.1875, 0.5}, {-0.5, -0.5, -0.5, 0.5, -0.1875, 0.5},
} }
} }
local hori3 = { local hori3 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -55,6 +61,7 @@ local hori3 = {
{-0.5, -0.5, -0.5, 0.5, -0.1875, 0.5}, {-0.5, -0.5, -0.5, 0.5, -0.1875, 0.5},
} }
} }
local hori4 = { local hori4 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -63,6 +70,7 @@ local hori4 = {
{-0.5, -0.5, -0.5, 0.5, -0.1875, 0.5}, {-0.5, -0.5, -0.5, 0.5, -0.1875, 0.5},
} }
} }
local cross1 = { local cross1 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -73,6 +81,7 @@ local cross1 = {
{0.1875, 0.1875, -0.5, 0.5, 0.5, 0.5}, {0.1875, 0.1875, -0.5, 0.5, 0.5, 0.5},
} }
} }
local cross2 = { local cross2 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -83,6 +92,7 @@ local cross2 = {
{0.1875, 0.1875, -0.5, 0.5, 0.5, 0.5}, {0.1875, 0.1875, -0.5, 0.5, 0.5, 0.5},
} }
} }
local cross3 = { local cross3 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -93,6 +103,7 @@ local cross3 = {
{0.1875, 0.1875, -0.5, 0.5, 0.5, 0.5}, {0.1875, 0.1875, -0.5, 0.5, 0.5, 0.5},
} }
} }
local cross4 = { local cross4 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -103,6 +114,7 @@ local cross4 = {
{0.1875, 0.1875, -0.5, 0.5, 0.5, 0.5}, {0.1875, 0.1875, -0.5, 0.5, 0.5, 0.5},
} }
} }
local chis1 = { local chis1 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -110,6 +122,7 @@ local chis1 = {
{-0.4375, -0.4375, -0.5, 0.4375, 0.4375, 0.5}, {-0.4375, -0.4375, -0.5, 0.4375, 0.4375, 0.5},
} }
} }
local chis2 = { local chis2 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -118,6 +131,7 @@ local chis2 = {
{-0.4375, -0.4375, -0.4375, 0.4375, 0.4375, 0.5}, {-0.4375, -0.4375, -0.4375, 0.4375, 0.4375, 0.5},
} }
} }
local chis3 = { local chis3 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -127,6 +141,7 @@ local chis3 = {
{-0.3125, -0.3125, -0.5, 0.3125, 0.3125, 0.5}, {-0.3125, -0.3125, -0.5, 0.3125, 0.3125, 0.5},
} }
} }
local chis4 = { local chis4 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -137,6 +152,7 @@ local chis4 = {
{-0.25, -0.25, -0.5, 0.25, 0.25, 0.5}, {-0.25, -0.25, -0.5, 0.25, 0.25, 0.5},
} }
} }
local squar1 = { local squar1 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -147,6 +163,7 @@ local squar1 = {
{-0.5, 0.3125, -0.5, 0.5, 0.5, -0.4375}, {-0.5, 0.3125, -0.5, 0.5, 0.5, -0.4375},
} }
} }
local squar2 = { local squar2 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -157,6 +174,7 @@ local squar2 = {
{-0.5, 0.3125, -0.5, 0.5, 0.5, -0.375}, {-0.5, 0.3125, -0.5, 0.5, 0.5, -0.375},
} }
} }
local squar3 = { local squar3 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -167,6 +185,7 @@ local squar3 = {
{-0.5, 0.3125, -0.5, 0.5, 0.5, -0.3125}, {-0.5, 0.3125, -0.5, 0.5, 0.5, -0.3125},
} }
} }
local squar4 = { local squar4 = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -195,11 +214,12 @@ local default_material = {
{"default:stonebrick","default_stone_brick", "Stone Brick", {cracky = 2, not_in_creative_inventory=1}}, {"default:stonebrick","default_stone_brick", "Stone Brick", {cracky = 2, not_in_creative_inventory=1}},
{"default:desert_stonebrick","default_desert_stone_brick", "Desert Stone Brick", {cracky = 2, not_in_creative_inventory=1}}, {"default:desert_stonebrick","default_desert_stone_brick", "Desert Stone Brick", {cracky = 2, not_in_creative_inventory=1}},
} }
for i in ipairs (default_material) do for i in ipairs (default_material) do
local item = default_material [i][1] local item = default_material [i][1]
local mat = default_material [i][2] local mat = default_material [i][2]
local desc = default_material [i][3] local desc = default_material [i][3]
local gro = default_material [i][4] local gro = default_material [i][4]
minetest.register_node("mychisel:vertical_"..mat.."1", { minetest.register_node("mychisel:vertical_"..mat.."1", {
description = "Vertical "..desc.."1", description = "Vertical "..desc.."1",
@ -219,8 +239,8 @@ minetest.register_node("mychisel:vertical_"..mat.."1", {
node_box = vert1, node_box = vert1,
selection_box = vert1, selection_box = vert1,
on_place = minetest.rotate_node, on_place = minetest.rotate_node,
}) })
minetest.register_node("mychisel:vertical_"..mat.."2", { minetest.register_node("mychisel:vertical_"..mat.."2", {
description = "Vertical "..desc.."2", description = "Vertical "..desc.."2",
drawtype = "nodebox", drawtype = "nodebox",
@ -238,8 +258,8 @@ minetest.register_node("mychisel:vertical_"..mat.."2", {
groups = gro, groups = gro,
node_box = vert2, node_box = vert2,
selection_box = vert2 selection_box = vert2
}) })
minetest.register_node("mychisel:vertical_"..mat.."3", { minetest.register_node("mychisel:vertical_"..mat.."3", {
description = "Vertical "..desc.."3", description = "Vertical "..desc.."3",
drawtype = "nodebox", drawtype = "nodebox",
@ -257,8 +277,8 @@ minetest.register_node("mychisel:vertical_"..mat.."3", {
groups = gro, groups = gro,
node_box = vert3, node_box = vert3,
selection_box = vert3 selection_box = vert3
}) })
minetest.register_node("mychisel:vertical_"..mat.."4", { minetest.register_node("mychisel:vertical_"..mat.."4", {
description = "Vertical "..desc.."4", description = "Vertical "..desc.."4",
drawtype = "nodebox", drawtype = "nodebox",
@ -276,8 +296,8 @@ minetest.register_node("mychisel:vertical_"..mat.."4", {
groups = gro, groups = gro,
node_box = vert4, node_box = vert4,
selection_box = vert4 selection_box = vert4
}) })
minetest.register_node("mychisel:chiseled_"..mat.."1", { minetest.register_node("mychisel:chiseled_"..mat.."1", {
description = "Chiseled"..desc.."1", description = "Chiseled"..desc.."1",
drawtype = "nodebox", drawtype = "nodebox",
@ -295,8 +315,8 @@ minetest.register_node("mychisel:chiseled_"..mat.."1", {
groups = gro, groups = gro,
node_box = chis1, node_box = chis1,
selection_box = chis1, selection_box = chis1,
}) })
minetest.register_node("mychisel:chiseled_"..mat.."2", { minetest.register_node("mychisel:chiseled_"..mat.."2", {
description = "Chiseled"..desc.."2", description = "Chiseled"..desc.."2",
drawtype = "nodebox", drawtype = "nodebox",
@ -314,8 +334,8 @@ minetest.register_node("mychisel:chiseled_"..mat.."2", {
groups = gro, groups = gro,
node_box = chis2, node_box = chis2,
selection_box = chis2 selection_box = chis2
}) })
minetest.register_node("mychisel:chiseled_"..mat.."3", { minetest.register_node("mychisel:chiseled_"..mat.."3", {
description = "Chiseled"..desc.."3", description = "Chiseled"..desc.."3",
drawtype = "nodebox", drawtype = "nodebox",
@ -333,8 +353,8 @@ minetest.register_node("mychisel:chiseled_"..mat.."3", {
groups = gro, groups = gro,
node_box = chis3, node_box = chis3,
selection_box = chis3 selection_box = chis3
}) })
minetest.register_node("mychisel:chiseled_"..mat.."4", { minetest.register_node("mychisel:chiseled_"..mat.."4", {
description = "Chiseled"..desc.."4", description = "Chiseled"..desc.."4",
drawtype = "nodebox", drawtype = "nodebox",
@ -352,8 +372,8 @@ minetest.register_node("mychisel:chiseled_"..mat.."4", {
groups = gro, groups = gro,
node_box = chis4, node_box = chis4,
selection_box = chis4 selection_box = chis4
}) })
minetest.register_node("mychisel:horizontal_"..mat.."1", { minetest.register_node("mychisel:horizontal_"..mat.."1", {
description = "Horizontal "..desc.."1", description = "Horizontal "..desc.."1",
drawtype = "nodebox", drawtype = "nodebox",
@ -371,8 +391,8 @@ minetest.register_node("mychisel:horizontal_"..mat.."1", {
groups = gro, groups = gro,
node_box = hori1, node_box = hori1,
selection_box = hori1 selection_box = hori1
}) })
minetest.register_node("mychisel:horizontal_"..mat.."2", { minetest.register_node("mychisel:horizontal_"..mat.."2", {
description = "Horizontal"..desc.."2", description = "Horizontal"..desc.."2",
drawtype = "nodebox", drawtype = "nodebox",
@ -390,8 +410,8 @@ minetest.register_node("mychisel:horizontal_"..mat.."2", {
groups = gro, groups = gro,
node_box = hori2, node_box = hori2,
selection_box = hori2 selection_box = hori2
}) })
minetest.register_node("mychisel:horizontal_"..mat.."3", { minetest.register_node("mychisel:horizontal_"..mat.."3", {
description = "Horizontal"..desc.."3", description = "Horizontal"..desc.."3",
drawtype = "nodebox", drawtype = "nodebox",
@ -410,6 +430,7 @@ minetest.register_node("mychisel:horizontal_"..mat.."3", {
node_box = hori3, node_box = hori3,
selection_box = hori3 selection_box = hori3
}) })
minetest.register_node("mychisel:horizontal_"..mat.."4", { minetest.register_node("mychisel:horizontal_"..mat.."4", {
description = "Horizontal"..desc.."4", description = "Horizontal"..desc.."4",
drawtype = "nodebox", drawtype = "nodebox",
@ -427,8 +448,8 @@ minetest.register_node("mychisel:horizontal_"..mat.."4", {
groups = gro, groups = gro,
node_box = hori4, node_box = hori4,
selection_box = hori4 selection_box = hori4
}) })
minetest.register_node("mychisel:cross_"..mat.."1", { minetest.register_node("mychisel:cross_"..mat.."1", {
description = "cross "..desc.."1", description = "cross "..desc.."1",
drawtype = "nodebox", drawtype = "nodebox",
@ -446,8 +467,8 @@ minetest.register_node("mychisel:cross_"..mat.."1", {
groups = gro, groups = gro,
node_box = cross1, node_box = cross1,
selection_box = cross1 selection_box = cross1
}) })
minetest.register_node("mychisel:cross_"..mat.."2", { minetest.register_node("mychisel:cross_"..mat.."2", {
description = "cross"..desc.."2", description = "cross"..desc.."2",
drawtype = "nodebox", drawtype = "nodebox",
@ -465,8 +486,8 @@ minetest.register_node("mychisel:cross_"..mat.."2", {
groups = gro, groups = gro,
node_box = cross2, node_box = cross2,
selection_box = cross2 selection_box = cross2
}) })
minetest.register_node("mychisel:cross_"..mat.."3", { minetest.register_node("mychisel:cross_"..mat.."3", {
description = "cross"..desc.."3", description = "cross"..desc.."3",
drawtype = "nodebox", drawtype = "nodebox",
@ -484,8 +505,8 @@ minetest.register_node("mychisel:cross_"..mat.."3", {
groups = gro, groups = gro,
node_box = cross3, node_box = cross3,
selection_box = cross3 selection_box = cross3
}) })
minetest.register_node("mychisel:cross_"..mat.."4", { minetest.register_node("mychisel:cross_"..mat.."4", {
description = "cross"..desc.."4", description = "cross"..desc.."4",
drawtype = "nodebox", drawtype = "nodebox",
@ -503,8 +524,8 @@ minetest.register_node("mychisel:cross_"..mat.."4", {
groups = gro, groups = gro,
node_box = cross4, node_box = cross4,
selection_box = cross4 selection_box = cross4
}) })
minetest.register_node("mychisel:square_"..mat.."1", { minetest.register_node("mychisel:square_"..mat.."1", {
description = "cross "..desc.."1", description = "cross "..desc.."1",
drawtype = "nodebox", drawtype = "nodebox",
@ -522,8 +543,8 @@ minetest.register_node("mychisel:square_"..mat.."1", {
groups = gro, groups = gro,
node_box = squar1, node_box = squar1,
selection_box = squar1 selection_box = squar1
}) })
minetest.register_node("mychisel:square_"..mat.."2", { minetest.register_node("mychisel:square_"..mat.."2", {
description = "cross"..desc.."2", description = "cross"..desc.."2",
drawtype = "nodebox", drawtype = "nodebox",
@ -541,8 +562,8 @@ minetest.register_node("mychisel:square_"..mat.."2", {
groups = gro, groups = gro,
node_box = squar2, node_box = squar2,
selection_box = squar2 selection_box = squar2
}) })
minetest.register_node("mychisel:square_"..mat.."3", { minetest.register_node("mychisel:square_"..mat.."3", {
description = "cross"..desc.."3", description = "cross"..desc.."3",
drawtype = "nodebox", drawtype = "nodebox",
@ -560,8 +581,8 @@ minetest.register_node("mychisel:square_"..mat.."3", {
groups = gro, groups = gro,
node_box = squar3, node_box = squar3,
selection_box = squar3 selection_box = squar3
}) })
minetest.register_node("mychisel:square_"..mat.."4", { minetest.register_node("mychisel:square_"..mat.."4", {
description = "cross"..desc.."4", description = "cross"..desc.."4",
drawtype = "nodebox", drawtype = "nodebox",
@ -581,4 +602,5 @@ minetest.register_node("mychisel:square_"..mat.."4", {
selection_box = squar4 selection_box = squar4
}) })
end end

Binary file not shown.

Before

Width:  |  Height:  |  Size: 189 KiB

After

Width:  |  Height:  |  Size: 181 KiB