Delete roundtarget

This commit is contained in:
Crizomb 2025-06-13 21:51:03 +02:00
parent 05f8b11dec
commit dbb296ff5d
5 changed files with 2 additions and 74 deletions

View file

@ -4,7 +4,6 @@
#define BOOK_GAME_HPP
#include "AudioEmitter.hpp"
#include "RoundTarget.hpp"
#include <SFML/Graphics.hpp>
class Game {
@ -25,7 +24,6 @@ private:
sf::RenderWindow mWindow{sf::VideoMode({640, 480}), "SFML Application"};
sf::Texture mTexture;
RoundTarget mTarget{35.f, sf::Color::Red, 320.f, 300.f};
sf::Font mFont;
sf::Text mStatisticsText{mFont};
sf::Time mStatisticsUpdateTime;

View file

@ -1,22 +0,0 @@
#ifndef SIMPLE_GAME_ROUND_TARGET_H
#define SIMPLE_GAME_ROUND_TARGET_H
#include <SFML/Graphics.hpp>
class RoundTarget {
public:
RoundTarget(float radius, sf::Color color, float x, float y);
void drawCurrent(sf::RenderWindow &window) const;
void handlePlayerInput(const sf::Keyboard::Key &key, const bool &isPressed);
void update(const sf::Time &elapsedTime);
private:
static constexpr float TargetSpeed{100.f};
bool mIsMovingUp{false};
bool mIsMovingDown{false};
bool mIsMovingRight{false};
bool mIsMovingLeft{false};
sf::CircleShape mShape;
};
#endif // SIMPLE_GAME_ROUND_TARGET_H