1
0
mirror of https://github.com/luanti-org/luanti.git synced 2025-10-13 00:25:19 +02:00

Fix warning in mg_decoration.cpp

This commit is contained in:
sfence
2025-04-17 12:35:14 +02:00
committed by GitHub
parent fd85737460
commit 7375358afd

View File

@@ -163,7 +163,7 @@ void Decoration::placeDeco(Mapgen *mg, u32 blockseed, v3s16 nmin, v3s16 nmax)
deco_count = deco_count_f;
} else if (deco_count_f > 0.0f) {
// For very low density calculate a chance for 1 decoration
if (ps.next() <= deco_count_f * PcgRandom::RANDOM_RANGE)
if (ps.next() <= deco_count_f * static_cast<float>(PcgRandom::RANDOM_RANGE))
deco_count = 1;
}
}