diff --git a/sources/Plansza.cpp b/sources/Plansza.cpp index 55738f2..5413583 100644 --- a/sources/Plansza.cpp +++ b/sources/Plansza.cpp @@ -720,7 +720,7 @@ void Plansza::spawn_meteor() { } void Plansza::spawn_hearts() { - if (heartSpawnClock.getElapsedTime().asSeconds() > float(RandomNumberGenerator::getRandomNumber(5,30))) { // randomowy spawn meteorytów od 5 do 30 sekundy + if (heartSpawnClock.getElapsedTime().asSeconds() > rand() % 26 + 5) { // randomowy spawn meteorytów od 5 do 30 sekundy if (hearts.size() < 5) { // jeśli jest mniej niż 5 meteorów na planszy hearts.emplace_back(RandomNumberGenerator::getRandomNumber(50, 499), -100, heartTexture); }