Fixed ores not spawning

This commit is contained in:
James David Clarke 2023-12-21 09:23:03 +00:00
parent 262048f072
commit d5ff3f436a
No known key found for this signature in database
GPG Key ID: 9F5ECFD0E20F1C4C
2 changed files with 19 additions and 12 deletions

View File

@ -57,21 +57,27 @@ moreores.mithril_clust_size_deep = 3
if minetest.get_modpath("mcl_core") then
-- Example adjustments for MineClone2
moreores.tin_max_depth_high = 0
moreores.tin_min_depth_high = -10
moreores.tin_max_depth = 0
moreores.tin_max_depth_high = 100
moreores.tin_min_depth_high = -57
moreores.tin_max_depth = 100
moreores.tin_min_depth = -57
moreores.tin_max_depth_deep = 100
moreores.tin_min_depth_deep = -57
-- Similar adjustments for silver and mithril
moreores.silver_max_depth_high = 0
moreores.silver_min_depth_high = -10
moreores.silver_max_depth = 0
moreores.silver_max_depth_high = 100
moreores.silver_min_depth_high = -57
moreores.silver_max_depth = 100
moreores.silver_min_depth = -57
moreores.silver_max_depth_deep = 100
moreores.silver_min_depth_deep = -57
moreores.mithril_max_depth_high = 0
moreores.mithril_min_depth_high = -20
moreores.mithril_max_depth = 0
moreores.mithril_max_depth_high = 100
moreores.mithril_min_depth_high = -57
moreores.mithril_max_depth = 100
moreores.mithril_min_depth = -57
moreores.mithril_max_depth_deep = 100
moreores.mithril_min_depth_deep = -57
else
-- Maximal and minimal depths of ore generation (Y coordinate, 0 being sea level by default)
-- Tin

View File

@ -28,8 +28,9 @@ local use_frame = minetest.get_modpath("frame")
local is_mcl_core_present = minetest.get_modpath("mcl_core") ~= nil
local is_mcl_sounds_present = minetest.get_modpath("mcl_sounds") ~= nil
local is_mcl_copper_present = minetest.registered_items["mcl_copper:copper_ingot"] ~= nil
local stone_ingrediant = mcl_core_modpath and "mcl_core:stone" or "default:stone"
local copper_ingrediant = mcl_core_modpath and "mcl_copper:copper_ingot" or 'default:copper_ingot'
local stone_ingrediant = is_mcl_core_present and "mcl_core:stone" or "default:stone"
local copper_ingrediant = is_mcl_core_present and "mcl_copper:copper_ingot" or 'default:copper_ingot'
local default_stone_sounds = nil
local default_metal_sounds = nil
@ -215,7 +216,7 @@ local function add_ore(modname, description, mineral_name, oredef, extra_node_de
oredef.oredef_deep.ore_type = "scatter"
oredef.oredef_deep.ore = modname .. ":mineral_" .. mineral_name
oredef.oredef_deep.wherein = stone_ingrediant
minetest.register_ore(oredef.oredef_high)
minetest.register_ore(oredef.oredef)
minetest.register_ore(oredef.oredef_deep)