mirror of
https://github.com/p2r3/bareiron.git
synced 2025-10-02 07:35:08 +02:00
adjust ore probability
This commit is contained in:
@@ -141,7 +141,7 @@ skip_tree:
|
|||||||
if (y == ore_y) {
|
if (y == ore_y) {
|
||||||
// Since the ore Y coordinate is effectely a random number in range [0;64],
|
// Since the ore Y coordinate is effectely a random number in range [0;64],
|
||||||
// we use it in another bit shift to get a pseudo-random number for the column
|
// we use it in another bit shift to get a pseudo-random number for the column
|
||||||
uint8_t ore_probability = (anchor.hash >> ore_y) & 127;
|
uint8_t ore_probability = (anchor.hash >> ore_y) & 255;
|
||||||
// Ore placement is determined by Y level and "probability"
|
// Ore placement is determined by Y level and "probability"
|
||||||
if (y < 15 && ore_probability < 15) return B_diamond_ore;
|
if (y < 15 && ore_probability < 15) return B_diamond_ore;
|
||||||
if (y < 30) {
|
if (y < 30) {
|
||||||
|
Reference in New Issue
Block a user