Uranium metal fixes

This commit is contained in:
mrkubax10 2023-02-27 20:18:20 +01:00
parent 6ea35bcae7
commit de538cc0db
2 changed files with 29 additions and 28 deletions

View File

@ -547,8 +547,6 @@ if industrialtest.mclAvailable then
}
})
-- ore generation is game-dependent so register it there
local stonelike={"mcl_core:stone","mcl_core:diorite","mcl_core:andesite","mcl_core:granite"}
minetest.register_ore({
ore_type="scatter",
ore="industrialtest:stone_with_tin",
@ -559,18 +557,8 @@ if industrialtest.mclAvailable then
y_max=mcl_worlds.layer_to_y(39),
y_min=mcl_vars.mg_overworld_min
})
minetest.register_ore({
ore_type="scatter",
ore="industrialtest:stone_with_uranium",
wherein=stonelike,
clust_scarcity=7*7*7,
clust_num_ores=3,
clust_size=3,
y_max=mcl_worlds.layer_to_y(20),
y_min=mcl_vars.mg_overworld_min
})
elseif industrialtest.mtgAvailable then
industrialtest.registerMetal=function(name,displayName,oreBlastResistance,oreHardness,rawBlockBlastResistance,rawBlockHardness,blockBlastResistance,blockHardness)
industrialtest.registerMetal=function(name,displayName,hardness)
minetest.register_craftitem("industrialtest:"..name.."_lump",{
description=S(displayName.." Lump"),
inventory_image="industrialtest_mtg_"..name.."_lump.png"
@ -584,12 +572,12 @@ elseif industrialtest.mtgAvailable then
tiles={"default_stone.png^industrialtest_mtg_stone_with_"..name..".png"},
sounds=default.node_sound_stone_defaults(),
drop="industrialtest:"..name.."_lump",
groups={cracky=oreHardness},
groups={cracky=hardness},
})
minetest.register_node("industrialtest:"..name.."_block",{
description=S("Block of "..displayName),
tiles={"industrialtest_"..name.."_block.png"},
groups={cracky=blockHardness,level=2},
groups={cracky=hardness,level=2},
sounds=default.node_sound_metal_defaults(),
})
minetest.register_craft({
@ -624,18 +612,6 @@ elseif industrialtest.mtgAvailable then
industrialtest.elementKeys.tinIngot="default:tin_ingot"
industrialtest.elementKeys.bronzeIngot="default:bronze_ingot"
industrialtest.elementKeys.stick="default:stick"
-- ore generation is game-dependent so register it there
minetest.register_ore({
ore_type="scatter",
ore="industrialtest:stone_with_uranium",
wherein="default:stone",
clust_scarcity=7*7*7,
clust_num_ores=3,
clust_size=3,
y_max=-128,
y_min=-31000
})
else
error("No compatible games found!")
end

View File

@ -14,4 +14,29 @@
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
industrialtest.registerMetal("uranium","Uranium",4,4)
if industrialtest.mtgAvailable then
industrialtest.registerMetal("uranium","Uranium",3)
minetest.register_ore({
ore_type="scatter",
ore="industrialtest:stone_with_uranium",
wherein="default:stone",
clust_scarcity=7*7*7,
clust_num_ores=3,
clust_size=3,
y_max=-128,
y_min=-31000
})
elseif industrialtest.mclAvailable then
industrialtest.registerMetal("uranium","Uranium",4,4,4,4,5,5)
local stonelike={"mcl_core:stone","mcl_core:diorite","mcl_core:andesite","mcl_core:granite"}
minetest.register_ore({
ore_type="scatter",
ore="industrialtest:stone_with_uranium",
wherein=stonelike,
clust_scarcity=7*7*7,
clust_num_ores=3,
clust_size=3,
y_max=mcl_worlds.layer_to_y(20),
y_min=mcl_vars.mg_overworld_min
})
end