fix serduszek
This commit is contained in:
@@ -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);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user