Skip to content
Snippets Groups Projects
Commit c265efe6 authored by Duane Robertson's avatar Duane Robertson
Browse files

Cooperate with fun_caves.

parent f01c2d49
No related branches found
No related tags found
No related merge requests found
......@@ -7,134 +7,124 @@ local newnode
local light_max = default.light_max or 10
if not minetest.registered_items['fun_caves:stalactite'] then
-- Speleothems can be made into cobblestone, to get them out of inventory.
minetest.register_craft({
output = "default:cobble",
recipe = {
{"", "", ""},
{"underworlds:stalactite", "underworlds:stalactite", ""},
{"underworlds:stalactite", "underworlds:stalactite", ""},
},
})
minetest.register_craft({
output = "default:cobble",
recipe = {
{"", "", ""},
{"underworlds:stalagmite", "underworlds:stalagmite", ""},
{"underworlds:stalagmite", "underworlds:stalagmite", ""},
},
})
-- What's a cave without speleothems?
local spel = {
{type1="stalactite", type2="stalagmite", tile="default_stone.png"},
{type1="stalactite_slimy", type2="stalagmite_slimy", tile="default_stone.png^underworlds_algae.png"},
{type1="stalactite_mossy", type2="stalagmite_mossy", tile="default_stone.png^underworlds_moss.png"},
{type1="icicle_down", type2="icicle_up", desc="Icicle", tile="caverealms_thin_ice.png", drop="default:ice"},
}
for _, desc in pairs(spel) do
minetest.register_node("underworlds:"..desc.type1, {
description = (desc.desc or "Stalactite"),
tiles = {desc.tile},
is_ground_content = true,
walkable = false,
paramtype = "light",
drop = (desc.drop or "underworlds:stalactite"),
drawtype = "nodebox",
node_box = { type = "fixed",
fixed = {
{-0.07, 0.0, -0.07, 0.07, 0.5, 0.07},
{-0.04, -0.25, -0.04, 0.04, 0.0, 0.04},
{-0.02, -0.5, -0.02, 0.02, 0.25, 0.02},
} },
groups = {rock=1, cracky=3},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_node("underworlds:"..desc.type2, {
description = (desc.desc or "Stalagmite"),
tiles = {desc.tile},
is_ground_content = true,
walkable = false,
paramtype = "light",
drop = "underworlds:stalagmite",
drawtype = "nodebox",
node_box = { type = "fixed",
fixed = {
{-0.07, -0.5, -0.07, 0.07, 0.0, 0.07},
{-0.04, 0.0, -0.04, 0.04, 0.25, 0.04},
{-0.02, 0.25, -0.02, 0.02, 0.5, 0.02},
} },
groups = {rock=1, cracky=3},
sounds = default.node_sound_stone_defaults(),
})
end
end
local spel = {
{type1="stalactite", type2="stalagmite", tile="default_stone.png"},
{type1="stalactite_slimy", type2="stalagmite_slimy", tile="default_stone.png^underworlds_algae.png"},
{type1="stalactite_mossy", type2="stalagmite_mossy", tile="default_stone.png^underworlds_moss.png"},
{type1="icicle_down", type2="icicle_up", desc="Icicle", tile="caverealms_thin_ice.png", drop="default:ice"},
}
-- Speleothems can be made into cobblestone, to get them out of inventory.
minetest.register_craft({
output = "default:cobble",
recipe = {
{"", "", ""},
{"underworlds:stalactite", "underworlds:stalactite", ""},
{"underworlds:stalactite", "underworlds:stalactite", ""},
},
})
if not minetest.registered_items['fun_caves:hot_stone'] then
-- stone, hot
minetest.register_node("underworlds:hot_stone", {
description = "Hot Stone",
tiles = {"default_desert_stone.png^[colorize:#FF0000:150"},
is_ground_content = true,
groups = {crumbly=2, surface_hot=3},
light_source = light_max - 5,
damage_per_second = 1,
sounds = default.node_sound_stone_defaults({
footstep = {name="default_stone_footstep", gain=0.25},
}),
})
end
minetest.register_craft({
output = "default:cobble",
recipe = {
{"", "", ""},
{"underworlds:stalagmite", "underworlds:stalagmite", ""},
{"underworlds:stalagmite", "underworlds:stalagmite", ""},
},
})
if not minetest.registered_items['fun_caves:glowing_fungal_stone'] then
-- Glowing fungal stone provides an eerie light.
minetest.register_node("underworlds:glowing_fungal_stone", {
description = "Glowing Fungal Stone",
tiles = {"default_stone.png^vmg_glowing_fungal.png",},
-- What's a cave without speleothems?
for _, desc in pairs(spel) do
minetest.register_node("underworlds:"..desc.type1, {
description = (desc.desc or "Stalactite"),
tiles = {desc.tile},
is_ground_content = true,
light_source = light_max - 4,
groups = {cracky=3, stone=1},
drop = {items={ {items={"default:cobble"},}, {items={"underworlds:glowing_fungus",},},},},
walkable = false,
paramtype = "light",
drop = (desc.drop or "underworlds:stalactite"),
drawtype = "nodebox",
node_box = { type = "fixed",
fixed = {
{-0.07, 0.0, -0.07, 0.07, 0.5, 0.07},
{-0.04, -0.25, -0.04, 0.04, 0.0, 0.04},
{-0.02, -0.5, -0.02, 0.02, 0.25, 0.02},
} },
groups = {rock=1, cracky=3},
sounds = default.node_sound_stone_defaults(),
})
-- Glowing fungus grows underground.
minetest.register_craftitem("underworlds:glowing_fungus", {
description = "Glowing Fungus",
drawtype = "plantlike",
minetest.register_node("underworlds:"..desc.type2, {
description = (desc.desc or "Stalagmite"),
tiles = {desc.tile},
is_ground_content = true,
walkable = false,
paramtype = "light",
tiles = {"vmg_glowing_fungus.png"},
inventory_image = "vmg_glowing_fungus.png",
groups = {dig_immediate = 3},
drop = "underworlds:stalagmite",
drawtype = "nodebox",
node_box = { type = "fixed",
fixed = {
{-0.07, -0.5, -0.07, 0.07, 0.0, 0.07},
{-0.04, 0.0, -0.04, 0.04, 0.25, 0.04},
{-0.02, 0.25, -0.02, 0.02, 0.5, 0.02},
} },
groups = {rock=1, cracky=3},
sounds = default.node_sound_stone_defaults(),
})
end
if not minetest.registered_items['fun_caves:black_sand'] then
-- black (oily) sand
local newnode = underworlds_mod.clone_node("default:sand")
newnode.description = "Black Sand"
newnode.tiles = {"underworlds_black_sand.png"}
newnode.groups['falling_node'] = 0
minetest.register_node("underworlds:black_sand", newnode)
end
-- stone, hot
minetest.register_node("underworlds:hot_stone", {
description = "Hot Stone",
tiles = {"default_desert_stone.png^[colorize:#FF0000:150"},
is_ground_content = true,
groups = {crumbly=2, surface_hot=3},
light_source = light_max - 5,
damage_per_second = 1,
sounds = default.node_sound_stone_defaults({
footstep = {name="default_stone_footstep", gain=0.25},
}),
})
if not minetest.registered_items['fun_caves:hot_cobble'] then
-- cobble, hot - cobble with lava instead of mortar XD
minetest.register_node("underworlds:hot_cobble", {
description = "Hot Cobble",
tiles = {"caverealms_hot_cobble.png"},
is_ground_content = true,
groups = {crumbly=2, surface_hot=3},
--light_source = 2,
damage_per_second = 1,
sounds = default.node_sound_stone_defaults({
footstep = {name="default_stone_footstep", gain=0.25},
}),
})
end
-- Glowing fungal stone provides an eerie light.
minetest.register_node("underworlds:glowing_fungal_stone", {
description = "Glowing Fungal Stone",
tiles = {"default_stone.png^vmg_glowing_fungal.png",},
is_ground_content = true,
light_source = light_max - 4,
groups = {cracky=3, stone=1},
drop = {items={ {items={"default:cobble"},}, {items={"underworlds:glowing_fungus",},},},},
sounds = default.node_sound_stone_defaults(),
})
-- Glowing fungus grows underground.
minetest.register_craftitem("underworlds:glowing_fungus", {
description = "Glowing Fungus",
drawtype = "plantlike",
paramtype = "light",
tiles = {"vmg_glowing_fungus.png"},
inventory_image = "vmg_glowing_fungus.png",
groups = {dig_immediate = 3},
})
-- black (oily) sand
local newnode = underworlds_mod.clone_node("default:sand")
newnode.description = "Black Sand"
newnode.tiles = {"underworlds_black_sand.png"}
newnode.groups['falling_node'] = 0
minetest.register_node("underworlds:black_sand", newnode)
-- cobble, hot - cobble with lava instead of mortar XD
minetest.register_node("underworlds:hot_cobble", {
description = "Hot Cobble",
tiles = {"caverealms_hot_cobble.png"},
is_ground_content = true,
groups = {crumbly=2, surface_hot=3},
--light_source = 2,
damage_per_second = 1,
sounds = default.node_sound_stone_defaults({
footstep = {name="default_stone_footstep", gain=0.25},
}),
})
newnode = underworlds_mod.clone_node("default:water_source")
newnode.description = "Poisonous Water"
......@@ -158,22 +148,20 @@ newnode.special_tiles[1].name = "underworlds_water_poison_flowing_animated.png"
newnode.tiles[1] = "underworlds_water_poison.png"
minetest.register_node("underworlds:water_poison_flowing", newnode)
if not minetest.registered_items['fun_caves:thin_ice'] then
-- ice, thin -- transparent
minetest.register_node("underworlds:thin_ice", {
description = "Thin Ice",
tiles = {"caverealms_thin_ice.png"},
is_ground_content = true,
groups = {cracky=3},
sounds = default.node_sound_glass_defaults(),
use_texture_alpha = true,
light_source = 1,
drawtype = "glasslike",
sunlight_propagates = true,
freezemelt = "default:water_source",
paramtype = "light",
})
end
-- ice, thin -- transparent
minetest.register_node("underworlds:thin_ice", {
description = "Thin Ice",
tiles = {"caverealms_thin_ice.png"},
is_ground_content = true,
groups = {cracky=3},
sounds = default.node_sound_glass_defaults(),
use_texture_alpha = true,
light_source = 1,
drawtype = "glasslike",
sunlight_propagates = true,
freezemelt = "default:water_source",
paramtype = "light",
})
-- Iron, hot
newnode = underworlds_mod.clone_node("default:steelblock")
......
......@@ -3,7 +3,7 @@
-- Distributed under the LGPLv2.1 (https://www.gnu.org/licenses/old-licenses/lgpl-2.1.en.html)
local DEBUG = true
local DEBUG = false
local max_depth = 31000
local seed_noise = {offset = 0, scale = 32768, seed = 5202, spread = {x = 80, y = 80, z = 80}, octaves = 2, persist = 0.4, lacunarity = 2}
......
screenshot-1.jpg

174 KiB

screenshot-2.jpg

83.4 KiB | W: | H:

screenshot-2.jpg

457 KiB | W: | H:

screenshot-2.jpg
screenshot-2.jpg
screenshot-2.jpg
screenshot-2.jpg
  • 2-up
  • Swipe
  • Onion skin
screenshot-3.jpg

89.7 KiB

screenshot-4.jpg

82.2 KiB | W: | H:

screenshot-4.jpg

255 KiB | W: | H:

screenshot-4.jpg
screenshot-4.jpg
screenshot-4.jpg
screenshot-4.jpg
  • 2-up
  • Swipe
  • Onion skin
screenshot-5.jpg

77.5 KiB | W: | H:

screenshot-5.jpg

129 KiB | W: | H:

screenshot-5.jpg
screenshot-5.jpg
screenshot-5.jpg
screenshot-5.jpg
  • 2-up
  • Swipe
  • Onion skin
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment