diff --git a/sumpf/birke.lua b/sumpf/birke.lua index 7aa60cd..520382a 100644 --- a/sumpf/birke.lua +++ b/sumpf/birke.lua @@ -7,13 +7,17 @@ minetest.register_node("sumpf:sapling", { paramtype = "light", walkable = false, groups = {snappy=2,dig_immediate=3,flammable=2}, + sounds = default.node_sound_leaves_defaults(), + furnace_burntime = 9, }) + minetest.register_node("sumpf:birk", { tiles = {"birke_mossytree.png"}, inventory_image = "birke_mossytree.png^birke_sapling.png", paramtype = "light", stack_max = 1024, groups = {snappy=2,dig_immediate=3}, + sounds = default.node_sound_leaves_defaults(), on_construct = function(pos) mache_birke(pos) end, @@ -45,6 +49,7 @@ minetest.register_node("sumpf:tree", { description = "Birch Trunk", tiles = {"birke_tree_top.png", "birke_tree_top.png", "birke_tree.png"}, groups = {tree=1,snappy=1,choppy=2,oddly_breakable_by_hand=1,flammable=2}, + sounds = default.node_sound_wood_defaults(), }) minetest.register_node("sumpf:tree_horizontal", { @@ -54,12 +59,14 @@ minetest.register_node("sumpf:tree_horizontal", { paramtype2 = "facedir", legacy_facedir_simple = true, groups = {tree=1,snappy=1,choppy=2,oddly_breakable_by_hand=1,flammable=2}, + sounds = default.node_sound_wood_defaults(), }) minetest.register_node("sumpf:mossytree", { description = "Mossy Birch Trunk", tiles = {"birke_tree_top.png", "sumpf.png", "birke_mossytree.png"}, groups = {tree=1,snappy=1,choppy=2,oddly_breakable_by_hand=1,flammable=2}, + sounds = default.node_sound_wood_defaults(), }) local function tree_crafts(input) @@ -109,7 +116,7 @@ local function add_tree_branch(pos, dir) p = {x=pos.x+i, y=pos.y+1, z=pos.z+k} n = minetest.env:get_node(p) if (n.name=="air") then - minetest.env:add_node(p, {name="sumpf:leaves"}) + minetest.env:add_node(p, {name="sumpf:leaves"}) end end end @@ -137,16 +144,19 @@ end minetest.register_abm({ nodenames = {"sumpf:sapling"}, interval = 10, - chance = 6, + chance = 16, action = function(pos) - mache_birke(pos) + if minetest.env:find_node_near(pos, 1, "group:crumbly") + and minetest.env:get_node_light(pos, nil) > 7 then + mache_birke(pos) + end end ,}) --function anti_generate(node, surfaces, minp, maxp, height_min, height_max, spread, habitat_size, habitat_nodes) if sumpf.enable_birches then minetest.register_on_generated(function(minp, maxp, seed) - generate("sumpf:birk", {"default:dirt_with_grass"}, minp, maxp, 20, 25, 100, 500, + generate("sumpf:birk", {"default:dirt_with_grass"}, minp, maxp, 20, 25, 100, 500, {"default:water_source"},30,{"default:desert_sand"}) end) end diff --git a/sumpf/depends.txt b/sumpf/depends.txt index 239f2dc..7adcd34 100644 --- a/sumpf/depends.txt +++ b/sumpf/depends.txt @@ -2,3 +2,4 @@ default riesenpilz jungletree habitat +bucket diff --git a/sumpf/init.lua b/sumpf/init.lua index f2f370f..c3ee33d 100644 --- a/sumpf/init.lua +++ b/sumpf/init.lua @@ -5,6 +5,20 @@ sounds: supertux (GPL) I looked at snow mod for mapgen and at the jungletree mod for birches. ]] +minetest.register_craft({ + output = "sumpf:junglestonebrick", + recipe = { + {"sumpf:junglestone", "sumpf:junglestone"}, + {"sumpf:junglestone", "sumpf:junglestone"}, + } +}) + +minetest.register_craft({ + output = "sumpf:junglestone 4", + recipe = { + {"sumpf:junglestonebrick"}, + } +}) minetest.register_node("sumpf:gras", { description = "Swamp Grass", @@ -21,10 +35,17 @@ minetest.register_node("sumpf:gras", { minetest.register_node("sumpf:junglestone", { description = "Swamp Stone", - tile_images = {"sumpfstein.png"}, + tile_images = {"sumpf_swampstone.png"}, groups = {cracky=3}, legacy_mineral = true, - sounds = SOUND, + sounds = default.node_sound_stone_defaults(), +}) + +minetest.register_node("sumpf:junglestonebrick", { + description = "Swamp Stone Brick", + tiles = {"sumpf_swampstone_brick.png"}, + groups = {cracky=2, stone=1}, + sounds = default.node_sound_stone_defaults(), }) minetest.register_node("sumpf:peat", { @@ -39,7 +60,7 @@ minetest.register_node("sumpf:peat", { minetest.register_node("sumpf:kohle", { description = "Coal Ore", - tiles = {"sumpfstein.png^default_mineral_coal.png"}, + tiles = {"sumpf_swampstone.png^default_mineral_coal.png"}, groups = {cracky=3}, drop = 'default:coal_lump', sounds = default.node_sound_stone_defaults(), @@ -47,7 +68,7 @@ minetest.register_node("sumpf:kohle", { minetest.register_node("sumpf:eisen", { description = "Iron Ore", - tiles = {"sumpfstein.png^default_mineral_iron.png"}, + tiles = {"sumpf_swampstone.png^default_mineral_iron.png"}, groups = {cracky=3}, drop = 'default:iron_lump', sounds = default.node_sound_stone_defaults(), @@ -63,7 +84,7 @@ minetest.register_node("sumpf:sumpf", { }) minetest.register_node("sumpf:sumpf2", { - tiles = {"sumpf.png","sumpfstein.png","sumpfstein.png^sumpf2.png"}, + tiles = {"sumpf.png","sumpf_swampstone.png","sumpf_swampstone.png^sumpf2.png"}, groups = {cracky=3}, drop = "sumpf:junglestone", sounds = default.node_sound_stone_defaults({ @@ -110,6 +131,14 @@ minetest.register_node("sumpf:dirtywater_source", { groups = {water=3, liquid=3, puts_out_fire=1}, }) +bucket.register_liquid( + "sumpf:dirtywater_source", + "sumpf:dirtywater_flowing", + "sumpf:bucket_dirtywater", + "bucket.png^sumpf_bucket_dirtywater.png", + "Swampwater Bucket" +) + sumpf = {} dofile(minetest.get_modpath("sumpf").."/settings.lua") dofile(minetest.get_modpath("sumpf") .. "/birke.lua") diff --git a/sumpf/textures/sumpf_bucket_dirtywater.png b/sumpf/textures/sumpf_bucket_dirtywater.png new file mode 100644 index 0000000..c289de7 Binary files /dev/null and b/sumpf/textures/sumpf_bucket_dirtywater.png differ diff --git a/sumpf/textures/sumpfstein.png b/sumpf/textures/sumpf_swampstone.png similarity index 100% rename from sumpf/textures/sumpfstein.png rename to sumpf/textures/sumpf_swampstone.png diff --git a/sumpf/textures/sumpf_swampstone_brick.png b/sumpf/textures/sumpf_swampstone_brick.png new file mode 100644 index 0000000..3b2592f Binary files /dev/null and b/sumpf/textures/sumpf_swampstone_brick.png differ