Bomber nie chce trzymac sie granic mapy da faq
This commit is contained in:
@@ -31,7 +31,7 @@ void Bomber::setRandomDirection() {
|
||||
if (position.x > 0) direction = DirectionB::Left;
|
||||
break;
|
||||
case 3:
|
||||
if (position.x < 1200) direction = DirectionB::Right;
|
||||
if (position.x < 600) direction = DirectionB::Right;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -577,7 +577,7 @@ void Plansza::spawn_advanced_enemy() {
|
||||
}
|
||||
|
||||
void Plansza::spawn_bomber() {
|
||||
if (BomberSpawnClock.getElapsedTime().asSeconds() >= 100) { // Spawn co 10 sekund
|
||||
if (BomberSpawnClock.getElapsedTime().asSeconds() >= 10) { // Spawn co 10 sekund
|
||||
int spawnX = RandomNumberGenerator::getRandomNumber(50, size.width - 50);
|
||||
BEnemies.emplace_back(spawnX, -50, BomberEnemyTexture, BombaTexture);
|
||||
std::cout << "Spawned Bomber Enemy at X: " << spawnX << std::endl;
|
||||
@@ -586,7 +586,7 @@ void Plansza::spawn_bomber() {
|
||||
}
|
||||
|
||||
void Plansza::spawn_kamikadze() {
|
||||
if (KamikadzeSpawnClock.getElapsedTime().asSeconds() >= 5) { // Spawn co 10 sekund
|
||||
if (KamikadzeSpawnClock.getElapsedTime().asSeconds() >= 50) { // Spawn co 10 sekund
|
||||
int spawnX = RandomNumberGenerator::getRandomNumber(50, size.width - 50);
|
||||
KEnemies.emplace_back(spawnX, -50, KamikadzeTexture);
|
||||
std::cout << "Spawned Kamikadze Enemy at X: " << spawnX << std::endl;
|
||||
|
||||
Reference in New Issue
Block a user