mirror of
https://github.com/luanti-org/luanti.git
synced 2025-07-27 17:28:41 +00:00
Fix warnings about an unused variables and implicit conversion (#10586)
This commit is contained in:
parent
68139a28eb
commit
8eb2cbac61
3 changed files with 6 additions and 3 deletions
|
@ -498,7 +498,11 @@ void OreVein::generate(MMVManip *vm, int mapseed, u32 blockseed,
|
|||
}
|
||||
|
||||
// randval ranges from -1..1
|
||||
float randval = (float)pr.next() / (pr.RANDOM_RANGE / 2) - 1.f;
|
||||
/*
|
||||
Note: can generate values slightly larger than 1
|
||||
but this can't be changed as mapgen must be deterministic accross versions.
|
||||
*/
|
||||
float randval = (float)pr.next() / float(pr.RANDOM_RANGE / 2) - 1.f;
|
||||
float noiseval = contour(noise->result[index]);
|
||||
float noiseval2 = contour(noise2->result[index]);
|
||||
if (noiseval * noiseval2 + randval * random_factor < nthresh)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue