Expand description
Ore vein generation during terrain fill.
Matches vanillaβs OreVeinifier. Evaluates the three vein density functions
(vein_toggle, vein_ridged, vein_gap) per solid block to decide whether
to replace stone with copper/iron ore, raw ore blocks, or filler (granite/tuff).
StructsΒ§
- OreVeinifier
- Ore vein generator. Holds cached block state IDs and the positional random splitter used for per-block randomness.
- Vein
Type π - A vein type with its Y range and block variants.
ConstantsΒ§
- CHANCE_
OF_ πRAW_ ORE_ BLOCK - Probability of placing a raw ore block instead of ore.
- EDGE_
ROUNDOFF_ πBEGIN - Within this many blocks of the vein typeβs Y boundary, the threshold tightens.
- MAX_
EDGE_ πROUNDOFF - Maximum tightening applied at the very edge of the Y range.
- MAX_
RICHNESS π - Maximum richness (at veininess >= 0.6).
- MIN_
RICHNESS π - Minimum richness (at veininess = 0.4).
- SKIP_
ORE_ πIF_ GAP_ BELOW - Vein gap noise must be above this to place ore (otherwise filler).
- VEININESS_
THRESHOLD π - Veininess magnitude must exceed this (after edge roundoff) to place any vein block.
- VEIN_
SOLIDNESS π - Probability of NOT skipping a vein block (nextFloat must be <= this).