fixed mining system + removed some blocks

This commit is contained in:
cale 2016-06-05 13:13:09 +02:00
parent d84e853baf
commit a0d08648e1
8 changed files with 105 additions and 78 deletions

View File

@ -304,6 +304,24 @@ minetest.register_craft({
}
})
minetest.register_craft({
output = "default:pick_copper",
recipe = {
{"", "furnace:copper_rod", ""},
{"", "default:string_strong", ""},
{"", "default:stick", ""},
}
})
minetest.register_craft({
output = "default:pick_diamond",
recipe = {
{"", "furnace:diamond_rod", ""},
{"", "default:string_strong", ""},
{"", "default:stick", ""},
}
})
minetest.register_craft({
output = "default:axe",
recipe = {

View File

@ -190,9 +190,9 @@ minetest.register_node("default:treasure_chest", {
inv:set_size("main", 8*4)
local items = default.treasure_chest_items
local item = items[math.random(#items)]
inv:add_item("main", {name = item, count = math.random(2,10)})
inv:add_item("main", {name = item, count = math.random(1,3)})
local item = items[math.random(#items)]
inv:add_item("main", {name = item, count = math.random(2,10)})
inv:add_item("main", {name = item, count = math.random(1,3)})
end,
after_dig_node = function(pos, oldnode, oldmetadata, digger)
local meta = minetest.get_meta(pos)
@ -615,24 +615,6 @@ minetest.register_node("default:frame", {
groups = {choppy = 3},
})
minetest.register_node("default:frame_with_wood", {
description = "Frame with Wood",
tiles = {"default_wood.png^default_frame.png"},
groups = {choppy = 3},
})
minetest.register_node("default:frame_with_stonebrick", {
description = "Frame with Stonebrick",
tiles = {"default_stonebrick.png^default_frame.png"},
groups = {choppy = 3},
})
minetest.register_node("default:frame_with_log", {
description = "Frame with Log",
tiles = {"default_log.png^default_frame.png"},
groups = {choppy = 3},
})
-- glass
minetest.register_node("default:glass", {
@ -644,25 +626,6 @@ minetest.register_node("default:glass", {
groups = {crumbly = 3},
})
minetest.register_node("default:glass_with_wood", {
description = "Glass with Wood",
tiles = {"default_wood.png^default_glass.png"},
groups = {crumbly = 3},
})
minetest.register_node("default:glass_with_log", {
description = "Glass with Log",
tiles = {"default_log.png^default_glass.png"},
groups = {crumbly = 3},
})
minetest.register_node("default:glass_with_stonebrick", {
description = "Glass with Stonebrick",
tiles = {"default_stonebrick.png^default_glass.png"},
groups = {crumbly = 3},
})
-- floor
default.register_floor = function(color)
@ -685,7 +648,7 @@ default.register_floor("black")
default.register_wool = function(color)
minetest.register_node("default:wool_"..color, {
description = color.." Wool",
tiles = {"default_wool.png^[colorize:"..color..":120"},
tiles = {"default_wool.png^[colorize:"..color..":130"},
groups = {crumbly=3},
})
end
@ -707,7 +670,6 @@ minetest.register_node("default:stone", {
max_items = 1,
items = {
{items = {'default:flint'},rarity = 5},
{items = {'default:stone_with_silver'},rarity = 60},
{items = {"default:stone_item 5"}},
}
},
@ -834,21 +796,21 @@ minetest.register_node("default:stone_with_iron", {
minetest.register_node("default:stone_with_copper", {
description = "Stone with Copper",
tiles = {"default_stone_with_copper.png"},
groups = {cracky = 2},
groups = {cracky = 1},
sounds = default.sounds.stone(),
})
minetest.register_node("default:stone_with_zinc", {
description = "Stone with Zinc",
tiles = {"default_stone_with_zinc.png"},
groups = {cracky = 3},
groups = {cracky = 1},
sounds = default.sounds.stone(),
})
minetest.register_node("default:stone_with_silver", {
description = "Stone with Silver",
tiles = {"default_stone_with_silver.png"},
groups = {cracky = 3},
groups = {hard = 3},
sounds = default.sounds.stone(),
})
@ -862,7 +824,7 @@ minetest.register_node("default:stone_with_gold", {
minetest.register_node("default:stone_with_diamond", {
description = "Stone with Diamond",
tiles = {"default_stone_with_diamond.png"},
groups = {cracky = 1},
groups = {hard = 2},
drop = "default:diamond",
sounds = default.sounds.stone(),
})
@ -870,7 +832,7 @@ minetest.register_node("default:stone_with_diamond", {
minetest.register_node("default:stone_with_ruby", {
description = "Stone with Ruby",
tiles = {"default_stone_with_ruby.png"},
groups = {cracky = 1},
groups = {hard = 1},
drop = "default:ruby",
sounds = default.sounds.stone(),
})
@ -915,15 +877,3 @@ minetest.register_node("default:rail", {
walkable = false,
groups = {choppy = 1, attached_node = 1},
})
minetest.register_node("default:wire", {
description = "Wire",
drawtype = "raillike",
tiles = {"default_wire.png", "default_wire_curve.png",
"default_wire_t.png", "default_wire_cross.png"},
inventory_image = "default_wire.png",
wield_image = "default_wire.png",
paramtype = "light",
walkable = false,
groups = {choppy = 1, attached_node = 1},
})

Binary file not shown.

After

Width:  |  Height:  |  Size: 292 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 354 B

View File

@ -14,9 +14,10 @@ minetest.register_item(":", {
}
})
-- wood
minetest.register_tool("default:simple_hammer", {
description = "Simple Hammer\n For Level: - \n Damage: 8",
description = "Simple Hammer",
inventory_image = "default_basic_hammer.png",
tool_capabilities = {
max_drop_level=3,
@ -24,12 +25,14 @@ minetest.register_tool("default:simple_hammer", {
cracky={times={[2]=2.00, [3]=1.00}, uses=10, maxlevel=1},
choppy={times={[2]=1.50, [3]=1.00}, uses=20, maxlevel=1}
},
damage_groups = {fleshy=8},
damage_groups = {fleshy=1},
}
})
-- flint
minetest.register_tool("default:flint_pick", {
description = "Flint Pick\n For Level: - \n Damage: 8",
description = "Flint Pick",
inventory_image = "default_flint_pick.png",
tool_capabilities = {
max_drop_level=3,
@ -37,12 +40,14 @@ minetest.register_tool("default:flint_pick", {
cracky={times={[2]=1.50, [3]=0.80}, uses=50, maxlevel=1},
choppy={times={[2]=1.50, [3]=1.00}, uses=20, maxlevel=1}
},
damage_groups = {fleshy=8},
damage_groups = {fleshy=2},
}
})
-- stone
minetest.register_tool("default:axe_stone", {
description = "Stone Axe\n For Level: - \n Damage: 5",
description = "Stone Axe",
inventory_image = "default_axe_stone.png",
tool_capabilities = {
max_drop_level=3,
@ -50,36 +55,38 @@ minetest.register_tool("default:axe_stone", {
cracky={times={[3]=1.50}, uses=5, maxlevel=1},
choppy={times={[2]=3.50, [3]=1.10}, uses=10, maxlevel=1}
},
damage_groups = {fleshy=5},
damage_groups = {fleshy=1},
}
})
-- iron
minetest.register_tool("default:axe", {
description = "Axe\n For Level: - \n Damage: 13",
description = "Iron Axe",
inventory_image = "default_axe.png",
tool_capabilities = {
max_drop_level=3,
groupcaps= {
choppy={times={[1]=1.00, [2]=0.40, [3]=0.30}, uses=70, maxlevel=1}
},
damage_groups = {fleshy=13},
damage_groups = {fleshy=2},
}
})
minetest.register_tool("default:saw", {
description = "Saw\n For Level: - \n Damage: 13",
description = "Iron Saw",
inventory_image = "default_saw.png",
tool_capabilities = {
max_drop_level=3,
groupcaps= {
choppy={times={[1]=0.30, [2]=0.20, [3]=0.10}, uses=70, maxlevel=1}
},
damage_groups = {fleshy=13},
damage_groups = {fleshy=1},
}
})
minetest.register_tool("default:pick", {
description = "Pick\n For Level: - \n Damage: 20",
description = "Iron Pick",
inventory_image = "default_pick.png",
tool_capabilities = {
max_drop_level=3,
@ -87,36 +94,72 @@ minetest.register_tool("default:pick", {
cracky={times={[1]=1.90, [2]=0.50, [3]=0.30}, uses=50, maxlevel=1},
choppy={times={[2]=3.50, [3]=1.10}, uses=50, maxlevel=1}
},
damage_groups = {fleshy=20},
damage_groups = {fleshy=2},
}
})
minetest.register_tool("default:shovel", {
description = "Shovel\n For Level: - \n Damage: 7",
description = "Iron Shovel",
inventory_image = "default_shovel.png",
tool_capabilities = {
max_drop_level=3,
groupcaps= {
crumbly={times={[1]=0.90, [2]=0.40, [3]=0.20}, uses=100, maxlevel=1}
},
damage_groups = {fleshy=7},
damage_groups = {fleshy=1},
}
})
-- blade
minetest.register_tool("default:blade", {
description = "Blade\n Level: - \n Damage: 10",
description = "Blade",
inventory_image = "default_blade.png",
tool_capabilities = {
max_drop_level=3,
groupcaps= {
leaves={times={[1]=0.50}, uses=1000, maxlevel=1}
},
damage_groups = {fleshy=10},
damage_groups = {fleshy=5},
}
})
-- copper
minetest.register_tool("default:pick_copper", {
description = "Copper Pick",
inventory_image = "default_pick_copper.png",
tool_capabilities = {
max_drop_level=3,
groupcaps= {
cracky={times={[1]=1.00, [2]=0.30, [3]=0.20}, uses=150, maxlevel=1},
hard={times={[2]=2.30, [3]=1.50}, uses=50, maxlevel=100},
choppy={times={[2]=3.50, [3]=1.10}, uses=50, maxlevel=50}
},
damage_groups = {fleshy=3},
}
})
-- diamond
minetest.register_tool("default:pick_diamond", {
description = "Diamond Pick",
inventory_image = "default_pick_diamond.png",
tool_capabilities = {
max_drop_level=3,
groupcaps= {
cracky={times={[1]=0.40, [2]=0.30, [3]=0.20}, uses=150, maxlevel=1},
hard={times={[1]=1.90, [2]=1.00, [3]=0.7}, uses=150, maxlevel=1},
choppy={times={[2]=3.50, [3]=1.10}, uses=100, maxlevel=1}
},
damage_groups = {fleshy=3},
}
})
-- other
minetest.register_tool("default:knife", {
description = "Knife\n Level: - \n Damage: 12",
description = "Knife",
inventory_image = "default_knife.png",
tool_capabilities = {
max_drop_level=3,
@ -124,12 +167,12 @@ minetest.register_tool("default:knife", {
leaves={times={[1]=0.10}, uses=1000, maxlevel=1},
choppy={times={[3]=2.00}, uses=50, maxlevel=1}
},
damage_groups = {fleshy=12},
damage_groups = {fleshy=7},
}
})
minetest.register_tool("default:knife_big", {
description = "Knife (big)\n Level: - \n Damage: 15",
description = "Knife (big)",
inventory_image = "default_knife.png",
wield_scale = {x = 1.5, y=1.5, z = 1},
tool_capabilities = {
@ -138,7 +181,7 @@ minetest.register_tool("default:knife_big", {
leaves={times={[1]=0.05}, uses=1000, maxlevel=1},
choppy={times={[3]=2.00}, uses=50, maxlevel=1}
},
damage_groups = {fleshy=15},
damage_groups = {fleshy=8},
}
})

View File

@ -46,6 +46,9 @@ minetest.register_abm({
elseif myinv:contains_item("main", {name = "default:stone_with_gold"}) then
minetest.get_meta(patternpos):get_inventory():add_item("main", {name = "furnace:gold_rod"})
myinv:remove_item("main", {name = "default:stone_with_gold"})
elseif myinv:contains_item("main", {name = "default:stone_with_copper"}) then
minetest.get_meta(patternpos):get_inventory():add_item("main", {name = "furnace:copper_rod"})
myinv:remove_item("main", {name = "default:stone_with_copper"})
end
end
if pattern == "furnace:pattern_blade" then
@ -181,6 +184,11 @@ minetest.register_craftitem("furnace:iron_rod", {
inventory_image = "furnace_iron_rod.png",
})
minetest.register_craftitem("furnace:copper_rod", {
description = "Copper Rod",
inventory_image = "furnace_copper_rod.png",
})
minetest.register_craftitem("furnace:gold_rod", {
description = "Gold Rod",
inventory_image = "furnace_gold_rod.png",
@ -272,3 +280,11 @@ minetest.register_node("furnace:steel_frame", {
paramtype = "light",
groups = {choppy = 2},
})
minetest.register_craft({
output = "furnace:diamond_rod",
recipe = {
{"furnace:iron_rod", "default:diamond"},
}
})

Binary file not shown.

After

Width:  |  Height:  |  Size: 254 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 254 B

After

Width:  |  Height:  |  Size: 305 B