Categories: MinecraftNews

More detailed version of Henrik Kniberg’s showcase of the new Ore Generation + Math behind it

A developer of Minecraft, Henrik Kniberg, had posted an image on twitter which showed how Ore Generation works in the new Snapshot 21w07a

I decided to look through the code of Minecraft to get some more details about how the new System functions.

Ores don't only generate with the new System. Redstone, Lapis and Coal generates using the old generation from before 21w07a, as well as the new one.

The way the old generation works is, that there is a Max amount of Veins that can generate in a Chunk. If that limit hasn't been reached yet, a Vein can generate. This Vein gets a Random Y level between it's Min and Max, where it then will Generate.

The way the New Generation works is that the there again is a Max amount of Veins that can generate in a chunk. The Ores also has a Base Y level and a number for Spreading. Whenever a new Vein is going to Generate, this formula will be use to determine it's Y level:

(Random number from 0 to Spread) + (Random number from 0 to Spread) – Spread + Base Y

In this way, the ores will Generate like described on Henrik's image.

https://preview.redd.it/3ntfm2wvw9i61.png?width=3828&format=png&auto=webp&s=5eff8f963b1ada907d02757a136688c0002fe2e1

Gamer

Share
Published by
Gamer

Recent Posts

Ledx have been so hard for me this wipe

Not being able to craft them sucks. Especially when everyone I talk to about it…

5 months ago

My interesting and unfortunate Gwent life

First I'd like to say I absolutely love this game it's quality. Basically I first…

5 months ago

Teacher Tuesday 12/Dec/2023 – ask your questions here!

Welcome to Teacher Tuesday, a thread where anyone can ask any type of question without…

5 months ago

This games balance is confusing

I’m kind of new/returning to gwent I played beta and obviously it’s a lot lot…

5 months ago

Summary of 10 Days of Draws from Chaffee’s Bundles

Level 1 Bag (Free with Atmosphere Level 2) 6 small consumable (First Aid, Repair, Fire…

5 months ago

Why is my crew at 135%?

Here's my crew - T34-85M - for the life of me I cant figure out…

5 months ago