mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-11-24 13:09:16 +01:00
Merge branch 'master' into feat/renderers-cleanup
This commit is contained in:
@@ -165,11 +165,11 @@ double Random(double min, double max)
|
||||
return dist(random_engine());
|
||||
}
|
||||
|
||||
int Random(int min, int max)
|
||||
int RandomInt(int min, int max)
|
||||
{
|
||||
if (max < min) { std::swap(min, max); } // std::uniform_int_distribution requires min <= max (inverted bounds are UB)
|
||||
std::uniform_int_distribution dist(min, max);
|
||||
return dist(random_engine());
|
||||
return dist(Global.local_random_engine);
|
||||
}
|
||||
|
||||
std::uint64_t true_random_seed()
|
||||
|
||||
Reference in New Issue
Block a user