1
0
Fork 0

Merge branch 'master' into beta

This commit is contained in:
Lizzy Fleckenstein 2021-04-12 17:31:58 +02:00
commit f540bc2bb1
23 changed files with 16 additions and 311 deletions

View File

@ -12,7 +12,7 @@ local vector_distance = vector.distance
-- range for mob count -- range for mob count
local aoc_range = 32 local aoc_range = 32
--[[ --[[
THIS IS THE BIG LIST OF ALL BIOMES - used for programming/updating mobs THIS IS THE BIG LIST OF ALL BIOMES - used for programming/updating mobs
@ -158,7 +158,6 @@ local mobs_spawn = minetest.settings:get_bool("mobs_spawn", true) ~= false
-- count how many mobs of one type are inside an area -- count how many mobs of one type are inside an area
local count_mobs = function(pos,mobtype) local count_mobs = function(pos,mobtype)
print(mobtype)
local num = 0 local num = 0
local objs = get_objects_inside_radius(pos, aoc_range) local objs = get_objects_inside_radius(pos, aoc_range)
for n = 1, #objs do for n = 1, #objs do
@ -170,12 +169,12 @@ local count_mobs = function(pos,mobtype)
num = num + 1 num = num + 1
end end
-- count passive mobs only -- count passive mobs only
else else
num = num + 1 num = num + 1
end end
end end
end end
return num return num
end end
@ -194,7 +193,7 @@ end
name: name:
the mobs name the mobs name
dimension: dimension:
"overworld" "overworld"
"nether" "nether"
"end" "end"
@ -531,7 +530,7 @@ local function biome_check(biome_list, biome_goal)
return false return false
end end
--todo mob limiting --todo mob limiting
--MAIN LOOP --MAIN LOOP
@ -552,11 +551,11 @@ if mobs_spawn then
if dimension == "void" or dimension == "default" then if dimension == "void" or dimension == "default" then
break -- ignore void and unloaded area break -- ignore void and unloaded area
end end
local min,max = decypher_limits(player_pos.y) local min,max = decypher_limits(player_pos.y)
local goal_pos = position_calculation(player_pos) local goal_pos = position_calculation(player_pos)
local spawning_position_list = find_nodes_in_area_under_air(new_vector(goal_pos.x,min,goal_pos.z), vector.new(goal_pos.x,max,goal_pos.z), {"group:solid", "group:water", "group:lava"}) local spawning_position_list = find_nodes_in_area_under_air(new_vector(goal_pos.x,min,goal_pos.z), vector.new(goal_pos.x,max,goal_pos.z), {"group:solid", "group:water", "group:lava"})
--couldn't find node --couldn't find node

View File

@ -46,56 +46,6 @@ minetest.register_craft({
} }
}) })
-- Stripped Bark
minetest.register_craft({
output = "mcl_core:stripped_oak_bark 3",
recipe = {
{ "mcl_core:stripped_oak", "mcl_core:stripped_oak" },
{ "mcl_core:stripped_oak", "mcl_core:stripped_oak" },
}
})
minetest.register_craft({
output = "mcl_core:stripped_acacia_bark 3",
recipe = {
{ "mcl_core:stripped_acacia", "mcl_core:stripped_acacia" },
{ "mcl_core:stripped_acacia", "mcl_core:stripped_acacia" },
}
})
minetest.register_craft({
output = "mcl_core:stripped_dark_oak_bark 3",
recipe = {
{ "mcl_core:stripped_dark_oak", "mcl_core:stripped_dark_oak" },
{ "mcl_core:stripped_dark_oak", "mcl_core:stripped_dark_oak" },
}
})
minetest.register_craft({
output = "mcl_core:stripped_birch_bark 3",
recipe = {
{ "mcl_core:stripped_birch", "mcl_core:stripped_birch" },
{ "mcl_core:stripped_birch", "mcl_core:stripped_birch" },
}
})
minetest.register_craft({
output = "mcl_core:stripped_spruce_bark 3",
recipe = {
{ "mcl_core:stripped_spruce", "mcl_core:stripped_spruce" },
{ "mcl_core:stripped_spruce", "mcl_core:stripped_spruce" },
}
})
minetest.register_craft({
output = "mcl_core:stripped_jungle_bark 3",
recipe = {
{ "mcl_core:stripped_jungle", "mcl_core:stripped_jungle" },
{ "mcl_core:stripped_jungle", "mcl_core:stripped_jungle" },
}
})
minetest.register_craft({ minetest.register_craft({
type = 'shapeless', type = 'shapeless',
output = 'mcl_core:mossycobble', output = 'mcl_core:mossycobble',

View File

@ -14,7 +14,6 @@ mcl_autogroup.register_diggroup("shearsy_wool")
mcl_autogroup.register_diggroup("shearsy_cobweb") mcl_autogroup.register_diggroup("shearsy_cobweb")
mcl_autogroup.register_diggroup("swordy") mcl_autogroup.register_diggroup("swordy")
mcl_autogroup.register_diggroup("swordy_cobweb") mcl_autogroup.register_diggroup("swordy_cobweb")
mcl_autogroup.register_diggroup("hoey")
-- Load files -- Load files
local modpath = minetest.get_modpath("mcl_core") local modpath = minetest.get_modpath("mcl_core")

View File

@ -1,4 +1,4 @@
-- Tree nodes: Wood, Wooden Planks, Sapling, Leaves, Stripped Wood -- Tree nodes: Wood, Wooden Planks, Sapling, Leaves
local S = minetest.get_translator("mcl_core") local S = minetest.get_translator("mcl_core")
local mod_screwdriver = minetest.get_modpath("screwdriver") ~= nil local mod_screwdriver = minetest.get_modpath("screwdriver") ~= nil
@ -48,166 +48,6 @@ local register_tree_trunk = function(subname, description_trunk, description_bar
}) })
end end
-- Register stripped trunk
minetest.register_node("mcl_core:stripped_oak", {
description = "Stripped Oak Log",
_doc_items_longdesc = "Stripped Oak Log is a log that has been stripped of it's bark.",
tiles = {"mcl_core_stripped_oak_top.png", "mcl_core_stripped_oak_top.png", "mcl_core_stripped_oak_side.png"},
is_ground_content = false,
paramtype2 = "facedir",
on_place = mcl_util.rotate_axis,
groups = {handy=1,axey=1, flammable=2, building_block=1, material_wood=1, fire_encouragement=5, fire_flammability=5, tree=1},
sounds = mcl_sounds.node_sound_wood_defaults(),
_mcl_blast_resistance = 10,
_mcl_hardness = 2,
})
minetest.register_node("mcl_core:stripped_acacia", {
description = "Stripped Acacia Log",
_doc_items_longdesc = "Stripped Acacia Log is a log that has been stripped of it's bark.",
tiles = {"mcl_core_stripped_acacia_top.png", "mcl_core_stripped_acacia_top.png", "mcl_core_stripped_acacia_side.png"},
is_ground_content = false,
paramtype2 = "facedir",
on_place = mcl_util.rotate_axis,
groups = {handy=1,axey=1, flammable=2, building_block=1, material_wood=1, fire_encouragement=5, fire_flammability=5, tree=1},
sounds = mcl_sounds.node_sound_wood_defaults(),
_mcl_blast_resistance = 10,
_mcl_hardness = 2,
})
minetest.register_node("mcl_core:stripped_dark_oak", {
description = "Stripped Dark Oak Log",
_doc_items_longdesc = "Stripped Dark Oak Log is a log that has been stripped of it's bark.",
tiles = {"mcl_core_stripped_dark_oak_top.png", "mcl_core_stripped_dark_oak_top.png", "mcl_core_stripped_dark_oak_side.png"},
is_ground_content = false,
paramtype2 = "facedir",
on_place = mcl_util.rotate_axis,
groups = {handy=1,axey=1, flammable=2, building_block=1, material_wood=1, fire_encouragement=5, fire_flammability=5, tree=1},
sounds = mcl_sounds.node_sound_wood_defaults(),
_mcl_blast_resistance = 10,
_mcl_hardness = 2,
})
minetest.register_node("mcl_core:stripped_birch", {
description = "Stripped Birch Log",
_doc_items_longdesc = "Stripped Birch Log is a log that has been stripped of it's bark.",
tiles = {"mcl_core_stripped_birch_top.png", "mcl_core_stripped_birch_top.png", "mcl_core_stripped_birch_side.png"},
is_ground_content = false,
paramtype2 = "facedir",
on_place = mcl_util.rotate_axis,
groups = {handy=1,axey=1, flammable=2, building_block=1, material_wood=1, fire_encouragement=5, fire_flammability=5, tree=1},
sounds = mcl_sounds.node_sound_wood_defaults(),
_mcl_blast_resistance = 10,
_mcl_hardness = 2,
})
minetest.register_node("mcl_core:stripped_spruce", {
description = "Stripped Spruce Log",
_doc_items_longdesc = "Stripped Spruce Log is a log that has been stripped of it's bark.",
tiles = {"mcl_core_stripped_spruce_top.png", "mcl_core_stripped_spruce_top.png", "mcl_core_stripped_spruce_side.png"},
is_ground_content = false,
paramtype2 = "facedir",
on_place = mcl_util.rotate_axis,
groups = {handy=1,axey=1, flammable=2, building_block=1, material_wood=1, fire_encouragement=5, fire_flammability=5, tree=1},
sounds = mcl_sounds.node_sound_wood_defaults(),
_mcl_blast_resistance = 10,
_mcl_hardness = 2,
})
minetest.register_node("mcl_core:stripped_jungle", {
description = "Stripped Jungle Log",
_doc_items_longdesc = "Stripped Jungle Log is a log that has been stripped of it's bark.",
tiles = {"mcl_core_stripped_jungle_top.png", "mcl_core_stripped_jungle_top.png", "mcl_core_stripped_jungle_side.png"},
is_ground_content = false,
paramtype2 = "facedir",
on_place = mcl_util.rotate_axis,
groups = {handy=1,axey=1, flammable=2, building_block=1, material_wood=1, fire_encouragement=5, fire_flammability=5, tree=1},
sounds = mcl_sounds.node_sound_wood_defaults(),
_mcl_blast_resistance = 10,
_mcl_hardness = 2,
})
-- Register stripped bark
minetest.register_node("mcl_core:stripped_oak_bark", {
description = "Stripped Oak Bark",
_doc_items_longdesc = "Stripped Oak Bark is a bark that has been stripped.",
tiles = {"mcl_core_stripped_oak_side.png"},
is_ground_content = false,
paramtype2 = "facedir",
on_place = mcl_util.rotate_axis,
groups = {handy=1,axey=1, flammable=2, building_block=1, material_wood=1, fire_encouragement=5, fire_flammability=5},
sounds = mcl_sounds.node_sound_wood_defaults(),
_mcl_blast_resistance = 10,
_mcl_hardness = 2,
})
minetest.register_node("mcl_core:stripped_acacia_bark", {
description = "Stripped Acacia Bark",
_doc_items_longdesc = "Stripped Acacia Bark is a bark that has been stripped.",
tiles = {"mcl_core_stripped_acacia_side.png"},
is_ground_content = false,
paramtype2 = "facedir",
on_place = mcl_util.rotate_axis,
groups = {handy=1,axey=1, flammable=2, building_block=1, material_wood=1, fire_encouragement=5, fire_flammability=5},
sounds = mcl_sounds.node_sound_wood_defaults(),
_mcl_blast_resistance = 10,
_mcl_hardness = 2,
})
minetest.register_node("mcl_core:stripped_dark_oak_bark", {
description = "Stripped Dark Oak Bark",
_doc_items_longdesc = "Stripped Dark Oak Bark is a bark that has been stripped.",
tiles = {"mcl_core_stripped_dark_oak_side.png"},
is_ground_content = false,
paramtype2 = "facedir",
on_place = mcl_util.rotate_axis,
groups = {handy=1,axey=1, flammable=2, building_block=1, material_wood=1, fire_encouragement=5, fire_flammability=5},
sounds = mcl_sounds.node_sound_wood_defaults(),
_mcl_blast_resistance = 10,
_mcl_hardness = 2,
})
minetest.register_node("mcl_core:stripped_birch_bark", {
description = "Stripped Birch Bark",
_doc_items_longdesc = "Stripped Birch Bark is a bark that has been stripped.",
tiles = {"mcl_core_stripped_birch_side.png"},
is_ground_content = false,
paramtype2 = "facedir",
on_place = mcl_util.rotate_axis,
groups = {handy=1,axey=1, flammable=2, building_block=1, material_wood=1, fire_encouragement=5, fire_flammability=5},
sounds = mcl_sounds.node_sound_wood_defaults(),
_mcl_blast_resistance = 10,
_mcl_hardness = 2,
})
minetest.register_node("mcl_core:stripped_spruce_bark", {
description = "Stripped Spruce Bark",
_doc_items_longdesc = "Stripped Spruce Bark is a bark that has been stripped.",
tiles = {"mcl_core_stripped_spruce_side.png"},
is_ground_content = false,
paramtype2 = "facedir",
on_place = mcl_util.rotate_axis,
groups = {handy=1,axey=1, flammable=2, building_block=1, material_wood=1, fire_encouragement=5, fire_flammability=5},
sounds = mcl_sounds.node_sound_wood_defaults(),
_mcl_blast_resistance = 10,
_mcl_hardness = 2,
})
minetest.register_node("mcl_core:stripped_jungle_bark", {
description = "Stripped Jungle Bark",
_doc_items_longdesc = "Stripped Jungles Bark is a bark that has been stripped.",
tiles = {"mcl_core_stripped_jungle_side.png"},
is_ground_content = false,
paramtype2 = "facedir",
on_place = mcl_util.rotate_axis,
groups = {handy=1,axey=1, flammable=2, building_block=1, material_wood=1, fire_encouragement=5, fire_flammability=5},
sounds = mcl_sounds.node_sound_wood_defaults(),
_mcl_blast_resistance = 10,
_mcl_hardness = 2,
})
local register_wooden_planks = function(subname, description, tiles) local register_wooden_planks = function(subname, description, tiles)
minetest.register_node("mcl_core:"..subname, { minetest.register_node("mcl_core:"..subname, {
description = description, description = description,
@ -268,19 +108,7 @@ local register_leaves = function(subname, description, longdesc, tiles, sapling,
tiles = tiles, tiles = tiles,
paramtype = "light", paramtype = "light",
stack_max = 64, stack_max = 64,
groups = { groups = {handy=1,shearsy=1,swordy=1, leafdecay=leafdecay_distance, flammable=2, leaves=1, deco_block=1, dig_by_piston=1, fire_encouragement=30, fire_flammability=60},
handy=1,
hoey=1,
shearsy=1,
swordy=1,
leafdecay=leafdecay_distance,
flammable=2,
leaves=1,
deco_block=1,
dig_by_piston=1,
fire_encouragement=30,
fire_flammability=60
},
drop = get_drops(0), drop = get_drops(0),
_mcl_shears_drop = true, _mcl_shears_drop = true,
sounds = mcl_sounds.node_sound_leaves_defaults(), sounds = mcl_sounds.node_sound_leaves_defaults(),
@ -386,4 +214,4 @@ register_leaves("birchleaves", S("Birch Leaves"), S("Birch leaves are grown from
-- Node aliases -- Node aliases
minetest.register_alias("default:acacia_tree", "mcl_core:acaciatree") minetest.register_alias("default:acacia_tree", "mcl_core:acaciatree")
minetest.register_alias("default:acacia_leaves", "mcl_core:acacialeaves") minetest.register_alias("default:acacia_leaves", "mcl_core:acacialeaves")

Binary file not shown.

Before

Width:  |  Height:  |  Size: 361 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 426 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 531 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 439 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 382 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 438 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 415 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 480 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 551 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 523 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 447 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 556 B

View File

@ -78,9 +78,6 @@ minetest.register_tool("mcl_farming:hoe_wood", {
}, },
_repair_material = "group:wood", _repair_material = "group:wood",
_mcl_toollike_wield = true, _mcl_toollike_wield = true,
_mcl_diggroups = {
hoey = { speed = 2, level = 1, uses = 60 }
},
}) })
minetest.register_craft({ minetest.register_craft({
@ -121,9 +118,6 @@ minetest.register_tool("mcl_farming:hoe_stone", {
}, },
_repair_material = "mcl_core:cobble", _repair_material = "mcl_core:cobble",
_mcl_toollike_wield = true, _mcl_toollike_wield = true,
_mcl_diggroups = {
hoey = { speed = 4, level = 3, uses = 132 }
},
}) })
minetest.register_craft({ minetest.register_craft({
@ -160,9 +154,6 @@ minetest.register_tool("mcl_farming:hoe_iron", {
}, },
_repair_material = "mcl_core:iron_ingot", _repair_material = "mcl_core:iron_ingot",
_mcl_toollike_wield = true, _mcl_toollike_wield = true,
_mcl_diggroups = {
hoey = { speed = 6, level = 4, uses = 251 }
},
}) })
minetest.register_craft({ minetest.register_craft({
@ -205,9 +196,6 @@ minetest.register_tool("mcl_farming:hoe_gold", {
}, },
_repair_material = "mcl_core:gold_ingot", _repair_material = "mcl_core:gold_ingot",
_mcl_toollike_wield = true, _mcl_toollike_wield = true,
_mcl_diggroups = {
hoey = { speed = 12, level = 2, uses = 33 }
},
}) })
minetest.register_craft({ minetest.register_craft({
@ -252,9 +240,6 @@ minetest.register_tool("mcl_farming:hoe_diamond", {
}, },
_repair_material = "mcl_core:diamond", _repair_material = "mcl_core:diamond",
_mcl_toollike_wield = true, _mcl_toollike_wield = true,
_mcl_diggroups = {
hoey = { speed = 8, level = 5, uses = 1562 }
},
}) })
minetest.register_craft({ minetest.register_craft({

View File

@ -146,7 +146,7 @@ minetest.register_node("mcl_farming:hay_block", {
paramtype2 = "facedir", paramtype2 = "facedir",
is_ground_content = false, is_ground_content = false,
on_place = mcl_util.rotate_axis, on_place = mcl_util.rotate_axis,
groups = {handy=1, hoey=1, flammable=2, fire_encouragement=60, fire_flammability=20, building_block=1, fall_damage_add_percent=-80}, groups = {handy=1, flammable=2, fire_encouragement=60, fire_flammability=20, building_block=1, fall_damage_add_percent=-80},
sounds = mcl_sounds.node_sound_leaves_defaults(), sounds = mcl_sounds.node_sound_leaves_defaults(),
on_rotate = on_rotate, on_rotate = on_rotate,
_mcl_blast_resistance = 0.5, _mcl_blast_resistance = 0.5,

View File

@ -176,7 +176,7 @@ minetest.register_node("mcl_nether:nether_wart_block", {
stack_max = 64, stack_max = 64,
tiles = {"mcl_nether_nether_wart_block.png"}, tiles = {"mcl_nether_nether_wart_block.png"},
is_ground_content = false, is_ground_content = false,
groups = {handy=1, hoey=1, building_block=1}, groups = {handy=1, building_block=1},
sounds = mcl_sounds.node_sound_leaves_defaults( sounds = mcl_sounds.node_sound_leaves_defaults(
{ {
footstep={name="default_dirt_footstep", gain=0.7}, footstep={name="default_dirt_footstep", gain=0.7},

View File

@ -779,7 +779,7 @@ minetest.register_node("mcl_ocean:dried_kelp_block", {
description = S("Dried Kelp Block"), description = S("Dried Kelp Block"),
_doc_items_longdesc = S("A decorative block that serves as a great furnace fuel."), _doc_items_longdesc = S("A decorative block that serves as a great furnace fuel."),
tiles = { "mcl_ocean_dried_kelp_top.png", "mcl_ocean_dried_kelp_bottom.png", "mcl_ocean_dried_kelp_side.png" }, tiles = { "mcl_ocean_dried_kelp_top.png", "mcl_ocean_dried_kelp_bottom.png", "mcl_ocean_dried_kelp_side.png" },
groups = { handy = 1, hoey = 1, building_block = 1, flammable = 2, fire_encouragement = 30, fire_flammability = 60 }, groups = { handy = 1, building_block = 1, flammable = 2, fire_encouragement = 30, fire_flammability = 60 },
sounds = mcl_sounds.node_sound_leaves_defaults(), sounds = mcl_sounds.node_sound_leaves_defaults(),
paramtype2 = "facedir", paramtype2 = "facedir",
on_place = mcl_util.rotate_axis, on_place = mcl_util.rotate_axis,

View File

@ -48,7 +48,7 @@ minetest.register_node("mcl_sponges:sponge", {
buildable_to = false, buildable_to = false,
stack_max = 64, stack_max = 64,
sounds = mcl_sounds.node_sound_dirt_defaults(), sounds = mcl_sounds.node_sound_dirt_defaults(),
groups = {handy=1, hoey=1, building_block=1}, groups = {handy=1, building_block=1},
on_place = function(itemstack, placer, pointed_thing) on_place = function(itemstack, placer, pointed_thing)
local pn = placer:get_player_name() local pn = placer:get_player_name()
if pointed_thing.type ~= "node" then if pointed_thing.type ~= "node" then
@ -136,7 +136,7 @@ minetest.register_node("mcl_sponges:sponge_wet", {
buildable_to = false, buildable_to = false,
stack_max = 64, stack_max = 64,
sounds = mcl_sounds.node_sound_dirt_defaults(), sounds = mcl_sounds.node_sound_dirt_defaults(),
groups = {handy=1, hoey=1, building_block=1}, groups = {handy=1, building_block=1},
on_place = place_wet_sponge, on_place = place_wet_sponge,
_mcl_blast_resistance = 0.6, _mcl_blast_resistance = 0.6,
_mcl_hardness = 0.6, _mcl_hardness = 0.6,

View File

@ -51,7 +51,6 @@ minetest.register_tool(":", {
handy = { speed = 1, level = 1, uses = 0 }, handy = { speed = 1, level = 1, uses = 0 },
axey = { speed = 1, level = 1, uses = 0 }, axey = { speed = 1, level = 1, uses = 0 },
shovely = { speed = 1, level = 1, uses = 0 }, shovely = { speed = 1, level = 1, uses = 0 },
hoey = { speed = 1, level = 1, uses = 0 },
pickaxey = { speed = 1, level = 0, uses = 0 }, pickaxey = { speed = 1, level = 0, uses = 0 },
swordy = { speed = 1, level = 0, uses = 0 }, swordy = { speed = 1, level = 0, uses = 0 },
swordy_cobweb = { speed = 1, level = 0, uses = 0 }, swordy_cobweb = { speed = 1, level = 0, uses = 0 },
@ -352,56 +351,6 @@ minetest.register_tool("mcl_tools:shovel_diamond", {
}) })
-- Axes -- Axes
local make_stripped_trunk = function(itemstack, placer, pointed_thing)
if pointed_thing.type == "node" then
local pos = minetest.get_pointed_thing_position(pointed_thing)
local node = minetest.get_node(pos)
local node_name = node.name
if placer and not placer:get_player_control().sneak then
if minetest.registered_nodes[node_name] and minetest.registered_nodes[node_name].on_rightclick then
return minetest.registered_nodes[node_name].on_rightclick(pointed_thing.under, node, placer, itemstack) or itemstack
end
end
if minetest.is_protected(pointed_thing.under, placer:get_player_name()) then
minetest.record_protection_violation(pointed_thing.under, placer:get_player_name())
return itemstack
end
if not minetest.is_creative_enabled(placer:get_player_name()) then
-- Add wear (as if digging a axey node)
local toolname = itemstack:get_name()
local wear = mcl_autogroup.get_wear(toolname, "axey")
itemstack:add_wear(wear)
end
if node_name == "mcl_core:tree" then
minetest.swap_node(pointed_thing.under, {name="mcl_core:stripped_oak"})
elseif node_name == "mcl_core:darktree" then
minetest.swap_node(pointed_thing.under, {name="mcl_core:stripped_dark_oak"})
elseif node_name == "mcl_core:acaciatree" then
minetest.swap_node(pointed_thing.under, {name="mcl_core:stripped_acacia"})
elseif node_name == "mcl_core:birchtree" then
minetest.swap_node(pointed_thing.under, {name="mcl_core:stripped_birch"})
elseif node_name == "mcl_core:sprucetree" then
minetest.swap_node(pointed_thing.under, {name="mcl_core:stripped_spruce"})
elseif node_name == "mcl_core:jungletree" then
minetest.swap_node(pointed_thing.under, {name="mcl_core:stripped_jungle"})
elseif node_name == "mcl_core:tree_bark" then
minetest.swap_node(pointed_thing.under, {name="mcl_core:stripped_oak_bark"})
elseif node_name == "mcl_core:darktree_bark" then
minetest.swap_node(pointed_thing.under, {name="mcl_core:stripped_dark_oak_bark"})
elseif node_name == "mcl_core:acaciatree_bark" then
minetest.swap_node(pointed_thing.under, {name="mcl_core:stripped_acacia_bark"})
elseif node_name == "mcl_core:birchtree_bark" then
minetest.swap_node(pointed_thing.under, {name="mcl_core:stripped_birch_bark"})
elseif node_name == "mcl_core:sprucetree_bark" then
minetest.swap_node(pointed_thing.under, {name="mcl_core:stripped_spruce_bark"})
elseif node_name == "mcl_core:jungletree_bark" then
minetest.swap_node(pointed_thing.under, {name="mcl_core:stripped_jungle_bark"})
end
end
return itemstack
end
minetest.register_tool("mcl_tools:axe_wood", { minetest.register_tool("mcl_tools:axe_wood", {
description = S("Wooden Axe"), description = S("Wooden Axe"),
_doc_items_longdesc = axe_longdesc, _doc_items_longdesc = axe_longdesc,
@ -415,7 +364,6 @@ minetest.register_tool("mcl_tools:axe_wood", {
damage_groups = {fleshy=7}, damage_groups = {fleshy=7},
punch_attack_uses = 30, punch_attack_uses = 30,
}, },
on_place = make_stripped_trunk,
sound = { breaks = "default_tool_breaks" }, sound = { breaks = "default_tool_breaks" },
_repair_material = "group:wood", _repair_material = "group:wood",
_mcl_toollike_wield = true, _mcl_toollike_wield = true,
@ -435,7 +383,6 @@ minetest.register_tool("mcl_tools:axe_stone", {
damage_groups = {fleshy=9}, damage_groups = {fleshy=9},
punch_attack_uses = 66, punch_attack_uses = 66,
}, },
on_place = make_stripped_trunk,
sound = { breaks = "default_tool_breaks" }, sound = { breaks = "default_tool_breaks" },
_repair_material = "mcl_core:cobble", _repair_material = "mcl_core:cobble",
_mcl_toollike_wield = true, _mcl_toollike_wield = true,
@ -456,7 +403,6 @@ minetest.register_tool("mcl_tools:axe_iron", {
damage_groups = {fleshy=9}, damage_groups = {fleshy=9},
punch_attack_uses = 126, punch_attack_uses = 126,
}, },
on_place = make_stripped_trunk,
sound = { breaks = "default_tool_breaks" }, sound = { breaks = "default_tool_breaks" },
_repair_material = "mcl_core:iron_ingot", _repair_material = "mcl_core:iron_ingot",
_mcl_toollike_wield = true, _mcl_toollike_wield = true,
@ -476,7 +422,6 @@ minetest.register_tool("mcl_tools:axe_gold", {
damage_groups = {fleshy=7}, damage_groups = {fleshy=7},
punch_attack_uses = 17, punch_attack_uses = 17,
}, },
on_place = make_stripped_trunk,
sound = { breaks = "default_tool_breaks" }, sound = { breaks = "default_tool_breaks" },
_repair_material = "mcl_core:gold_ingot", _repair_material = "mcl_core:gold_ingot",
_mcl_toollike_wield = true, _mcl_toollike_wield = true,
@ -496,7 +441,6 @@ minetest.register_tool("mcl_tools:axe_diamond", {
damage_groups = {fleshy=9}, damage_groups = {fleshy=9},
punch_attack_uses = 781, punch_attack_uses = 781,
}, },
on_place = make_stripped_trunk,
sound = { breaks = "default_tool_breaks" }, sound = { breaks = "default_tool_breaks" },
_repair_material = "mcl_core:diamond", _repair_material = "mcl_core:diamond",
_mcl_toollike_wield = true, _mcl_toollike_wield = true,

View File

@ -156,7 +156,7 @@ minetest.register_globalstep(function(dtime)
for _,player in pairs(get_connected_players()) do for _,player in pairs(get_connected_players()) do
c_x, c_y = unpack(player_collision(player)) local c_x, c_y = unpack(player_collision(player))
if player:get_velocity().x + player:get_velocity().y < .5 and c_x + c_y > 0 then if player:get_velocity().x + player:get_velocity().y < .5 and c_x + c_y > 0 then
--minetest.chat_send_player(player:get_player_name(), "pushed at " .. c_x + c_y .. " parsecs.") --minetest.chat_send_player(player:get_player_name(), "pushed at " .. c_x + c_y .. " parsecs.")