Multiple changes:

- Adjust giant tree spawns.
- Remove dragon from dungeons.
- Adjust all abms.
- Allow giant trees to grow back damage.
- Revamp ice trap.
- Fix iron moonstone and coral teleporters.
This commit is contained in:
Duane 2016-06-18 06:35:48 -05:00
parent fa86013731
commit 6c764f0c3b
11 changed files with 210 additions and 68 deletions

149
nodes.lua
View file

@ -145,7 +145,13 @@ local function teleporter(user, area, power)
if area == 'overworld' then
newpos = {x=(math.random(2)*2-3)*(math.random(math.floor(max_depth/6))+power*math.floor(max_depth/6)), y=120, z=(math.random(2)*2-3)*(math.random(math.floor(max_depth/6))+power*math.floor(max_depth/6))}
elseif area == 'hell' then
newpos = {x=pos.x, y=fun_caves.underzones[({'Caina','Phlegethos','Dis','Minauros','Styx'})[power+1]].ceiling-30, z=pos.z}
newpos = {x=pos.x, y=fun_caves.underzones[({'Caina','Phlegethos','Dis','Minauros', 'Phlegethos','Styx'})[power+1]].ceiling-30, z=pos.z}
elseif area == 'sky' then
newpos = {x=pos.x, y=({4368, 8768, 13168, 4368, 4368, 4368})[power+1]+76, z=pos.z}
elseif area == 'dungeon' then
return
elseif area == 'underworld' then
return
else
return
end
@ -162,10 +168,61 @@ local function teleporter(user, area, power)
end
end
minetest.register_craftitem("fun_caves:teleporter_iron_coral", {
minetest.register_craftitem("fun_caves:teleporter_iron_moonstone", {
description = "Iron and Moonstone Teleporter",
drawtype = "plantlike",
paramtype = "light",
tiles = {"fun_caves_tesseract_iron_moon.png"},
inventory_image = "fun_caves_tesseract_iron_moon.png",
groups = {dig_immediate = 3},
sounds = default.node_sound_stone_defaults(),
on_use = function(itemstack, user, pointed_thing)
teleporter(user, 'sky', 0)
end,
})
minetest.register_craft({
output = 'fun_caves:teleporter_iron_moonstone',
recipe = {
{'fun_caves:sky_iron', 'fun_caves:pure_copper', 'fun_caves:sky_iron'},
{'fun_caves:moonstone', 'fun_caves:moonstone', 'fun_caves:moonstone'},
{'fun_caves:sky_iron', 'default:obsidian_shard', 'fun_caves:sky_iron'},
}
})
minetest.register_craftitem("fun_caves:moonstone", {
description = "Moonstone",
drawtype = "plantlike",
paramtype = "light",
tiles = {"fun_caves_moonstone.png"},
inventory_image = "fun_caves_moonstone.png",
groups = {dig_immediate = 3},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_node("fun_caves:stone_with_moonstones", {
description = "Moonstone Ore",
tiles = {"default_stone.png^fun_caves_mineral_moonstone.png"},
groups = {cracky = 1},
drop = "fun_caves:moonstone",
sounds = default.node_sound_stone_defaults(),
})
minetest.register_ore({
ore_type = "scatter",
ore = "fun_caves:stone_with_moonstones",
wherein = "default:stone",
clust_scarcity = 21 * 21 * 21,
clust_num_ores = 1,
clust_size = 1,
y_min = -31000,
y_max = 31000,
})
minetest.register_craftitem("fun_caves:teleporter_iron_coral", {
description = "Iron and Coral Teleporter",
drawtype = "plantlike",
paramtype = "light",
tiles = {"fun_caves_tesseract_iron_coral.png"},
inventory_image = "fun_caves_tesseract_iron_coral.png",
groups = {dig_immediate = 3},
@ -178,7 +235,7 @@ minetest.register_craftitem("fun_caves:teleporter_iron_coral", {
minetest.register_craft({
output = 'fun_caves:teleporter_iron_coral',
recipe = {
{'fun_caves:sky_iron', 'default:copper_ingot', 'fun_caves:sky_iron'},
{'fun_caves:sky_iron', 'fun_caves:pure_copper', 'fun_caves:sky_iron'},
{'fun_caves:coral_gem', 'fun_caves:coral_gem', 'fun_caves:coral_gem'},
{'fun_caves:sky_iron', 'default:obsidian_shard', 'fun_caves:sky_iron'},
}
@ -217,14 +274,14 @@ minetest.register_craftitem("fun_caves:teleporter_iron_garnet", {
minetest.register_craft({
output = 'fun_caves:teleporter_iron_garnet',
recipe = {
{'fun_caves:sky_iron', 'default:copper_ingot', 'fun_caves:sky_iron'},
{'fun_caves:perfect_garnet', 'fun_caves:perfect_garnet', 'fun_caves:perfect_garnet'},
{'fun_caves:sky_iron', 'fun_caves:pure_copper', 'fun_caves:sky_iron'},
{'fun_caves:garnet', 'fun_caves:garnet', 'fun_caves:garnet'},
{'fun_caves:sky_iron', 'default:obsidian_shard', 'fun_caves:sky_iron'},
}
})
minetest.register_craftitem("fun_caves:perfect_garnet", {
description = "Perfect Garnet",
minetest.register_craftitem("fun_caves:garnet", {
description = "Garnet",
drawtype = "plantlike",
paramtype = "light",
tiles = {"fun_caves_garnet.png"},
@ -237,7 +294,7 @@ minetest.register_node("fun_caves:stone_with_garnets", {
description = "Garnet Ore",
tiles = {"default_stone.png^fun_caves_mineral_garnet.png"},
groups = {cracky = 1},
drop = "fun_caves:perfect_garnet",
drop = "fun_caves:garnet",
sounds = default.node_sound_stone_defaults(),
})
@ -245,7 +302,7 @@ minetest.register_ore({
ore_type = "scatter",
ore = "fun_caves:stone_with_garnets",
wherein = "default:stone",
clust_scarcity = 17 * 17 * 17,
clust_scarcity = 21 * 21 * 21,
clust_num_ores = 1,
clust_size = 1,
y_min = -31000,
@ -261,21 +318,21 @@ minetest.register_craftitem("fun_caves:teleporter_iron_zoisite", {
groups = {dig_immediate = 3},
sounds = default.node_sound_stone_defaults(),
on_use = function(itemstack, user, pointed_thing)
teleporter(user, 'underworld', 0)
teleporter(user, 'dungeon', 0)
end,
})
minetest.register_craft({
output = 'fun_caves:teleporter_iron_zoisite',
recipe = {
{'fun_caves:sky_iron', 'default:copper_ingot', 'fun_caves:sky_iron'},
{'fun_caves:perfect_zoisite', 'fun_caves:perfect_zoisite', 'fun_caves:perfect_zoisite'},
{'fun_caves:sky_iron', 'fun_caves:pure_copper', 'fun_caves:sky_iron'},
{'fun_caves:zoisite', 'fun_caves:zoisite', 'fun_caves:zoisite'},
{'fun_caves:sky_iron', 'default:obsidian_shard', 'fun_caves:sky_iron'},
}
})
minetest.register_craftitem("fun_caves:perfect_zoisite", {
description = "Perfect Zoisite",
minetest.register_craftitem("fun_caves:zoisite", {
description = "Zoisite",
drawtype = "plantlike",
paramtype = "light",
tiles = {"fun_caves_zoisite.png"},
@ -288,7 +345,7 @@ minetest.register_node("fun_caves:stone_with_zoisites", {
description = "Zoisite Ore",
tiles = {"default_stone.png^fun_caves_mineral_zoisite.png"},
groups = {cracky = 1},
drop = "fun_caves:perfect_zoisite",
drop = "fun_caves:zoisite",
sounds = default.node_sound_stone_defaults(),
})
@ -296,7 +353,7 @@ minetest.register_ore({
ore_type = "scatter",
ore = "fun_caves:stone_with_zoisites",
wherein = "default:stone",
clust_scarcity = 17 * 17 * 17,
clust_scarcity = 21 * 21 * 21,
clust_num_ores = 1,
clust_size = 1,
y_min = -31000,
@ -319,14 +376,14 @@ minetest.register_craftitem("fun_caves:teleporter_iron_aquamarine", {
minetest.register_craft({
output = 'fun_caves:teleporter_iron_aquamarine',
recipe = {
{'fun_caves:sky_iron', 'default:copper_ingot', 'fun_caves:sky_iron'},
{'fun_caves:perfect_aquamarine', 'fun_caves:perfect_aquamarine', 'fun_caves:perfect_aquamarine'},
{'fun_caves:sky_iron', 'fun_caves:pure_copper', 'fun_caves:sky_iron'},
{'fun_caves:aquamarine', 'fun_caves:aquamarine', 'fun_caves:aquamarine'},
{'fun_caves:sky_iron', 'default:obsidian_shard', 'fun_caves:sky_iron'},
}
})
minetest.register_craftitem("fun_caves:perfect_aquamarine", {
description = "Perfect Aquamarine",
minetest.register_craftitem("fun_caves:aquamarine", {
description = "Aquamarine",
drawtype = "plantlike",
paramtype = "light",
tiles = {"fun_caves_aquamarine.png"},
@ -339,7 +396,7 @@ minetest.register_node("fun_caves:stone_with_aquamarines", {
description = "Aquamarine Ore",
tiles = {"default_stone.png^fun_caves_mineral_aquamarine.png"},
groups = {cracky = 1},
drop = "fun_caves:perfect_aquamarine",
drop = "fun_caves:aquamarine",
sounds = default.node_sound_stone_defaults(),
})
@ -347,7 +404,7 @@ minetest.register_ore({
ore_type = "scatter",
ore = "fun_caves:stone_with_aquamarines",
wherein = "default:stone",
clust_scarcity = 17 * 17 * 17,
clust_scarcity = 21 * 21 * 21,
clust_num_ores = 1,
clust_size = 1,
y_min = -31000,
@ -405,6 +462,42 @@ minetest.register_craft({
cooktime = 30,
})
minetest.register_craftitem("fun_caves:pure_copper", {
description = "Very Pure Copper",
drawtype = "plantlike",
paramtype = "light",
tiles = {"default_copper_ingot.png"},
inventory_image = "default_copper_ingot.png",
groups = {dig_immediate = 3},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_craftitem("fun_caves:copper_crucible", {
description = "Crucible of Copper",
drawtype = "plantlike",
paramtype = "light",
tiles = {"fun_caves_crucible.png"},
inventory_image = "fun_caves_crucible.png",
groups = {dig_immediate = 3},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_craft({
output = 'fun_caves:copper_crucible',
recipe = {
{'default:copper_ingot', 'default:copper_ingot', 'default:copper_ingot'},
{'default:copper_ingot', 'default:copper_ingot', 'default:copper_ingot'},
{'default:copper_ingot', 'fun_caves:crucible', 'default:copper_ingot'},
}
})
minetest.register_craft({
type = "cooking",
output = "fun_caves:pure_copper",
recipe = "fun_caves:copper_crucible",
cooktime = 30,
})
minetest.register_craftitem("fun_caves:crucible", {
description = "Crucible",
@ -433,12 +526,12 @@ newnode.groups.soil = 0
minetest.register_node("fun_caves:meteorite_crater", newnode)
local treasures = {
{'fun_caves:perfect_aquamarine', 'fun_caves:perfect_garnet', 'fun_caves:perfect_zoisite', 'fun_caves:coral_gem', 'fun_caves:sky_iron', 'fun_caves:sky_iron', 'fun_caves:sky_iron', 'fun_caves:sky_iron', 'default:obsidian'},
{'fun_caves:perfect_aquamarine', 'fun_caves:perfect_garnet', 'fun_caves:perfect_zoisite', 'fun_caves:coral_gem', 'fun_caves:pure_copper', 'fun_caves:pure_copper', 'fun_caves:pure_copper', 'fun_caves:pure_copper', 'default:obsidian'},
{'fun_caves:perfect_aquamarine', 'fun_caves:perfect_garnet', 'fun_caves:perfect_zoisite', 'fun_caves:coral_gem', 'default:obsidian'},
{'fun_caves:perfect_aquamarine', 'fun_caves:perfect_garnet', 'fun_caves:perfect_zoisite', 'fun_caves:coral_gem', 'default:obsidian'},
{'fun_caves:perfect_aquamarine', 'fun_caves:perfect_garnet', 'fun_caves:perfect_zoisite', 'fun_caves:coral_gem', 'default:obsidian'},
{'fun_caves:perfect_aquamarine', 'fun_caves:perfect_garnet', 'fun_caves:perfect_zoisite', 'fun_caves:coral_gem', 'default:obsidian'},
{'fun_caves:aquamarine', 'fun_caves:garnet', 'fun_caves:zoisite', 'fun_caves:coral_gem', 'fun_caves:moonstone', 'fun_caves:sky_iron', 'fun_caves:sky_iron', 'fun_caves:sky_iron', 'fun_caves:sky_iron', 'default:obsidian'},
{'fun_caves:aquamarine', 'fun_caves:garnet', 'fun_caves:zoisite', 'fun_caves:coral_gem', 'fun_caves:moonstone', 'fun_caves:pure_copper', 'fun_caves:pure_copper', 'fun_caves:pure_copper', 'fun_caves:pure_copper', 'default:obsidian'},
{'fun_caves:aquamarine', 'fun_caves:garnet', 'fun_caves:zoisite', 'fun_caves:coral_gem', 'fun_caves:moonstone', 'default:obsidian'},
{'fun_caves:aquamarine', 'fun_caves:garnet', 'fun_caves:zoisite', 'fun_caves:coral_gem', 'fun_caves:moonstone', 'default:obsidian'},
{'fun_caves:aquamarine', 'fun_caves:garnet', 'fun_caves:zoisite', 'fun_caves:coral_gem', 'fun_caves:moonstone', 'default:obsidian'},
{'fun_caves:aquamarine', 'fun_caves:garnet', 'fun_caves:zoisite', 'fun_caves:coral_gem', 'fun_caves:moonstone', 'default:obsidian'},
}
local filler = {'default:apple 10', 'default:coal_lump 10', 'default:wood 10'}
local trophies = {