ouverture de fenetre possible

faire le Game::run
This commit is contained in:
YANNIS
2025-05-29 18:25:10 +02:00
parent bd9bc5e2e2
commit 62a0b9719f
10 changed files with 91 additions and 68 deletions
+12 -16
View File
@@ -1,21 +1,17 @@
// Bomberman.hpp
#pragma once
#include <iostream>
#include "Position.hpp"
#include "Bomb.hpp"
class Bomberman {
#include<iostream>
class Bomberman {
private:
Position _position;
unsigned short _maxNumberOfBombs = 1;
unsigned short _numberOfBombsPlanted = 0;
Bomb _bomb;
int _x, _y;
unsigned short _maxBomb = 1;
unsigned short _maxRange = 1;
unsigned short _bombPlanted = 0;
float _speed = 1.0f;
bool _isAlive = true;
bool _isInvincible = false;
public:
Bomberman(){std::cout << "Bomberman created!" << std::endl;}
~Bomberman(){std::cout << "Bomberman destroyed!" << std::endl;};
int plantBomb();
friend std::ostream& operator<<(std::ostream &os, const Bomberman &bomberman) {
os << "Bomberman at " << bomberman._position << ", Number of bombs: " << bomberman._numberOfBombs;
return os;
}
Bomberman() = default;
~Bomberman() = default;
friend std::ostream& operator<<(std::ostream& os, const Bomberman& b);
};