Upload files to "/"

This commit is contained in:
Wolf 2026-01-09 10:21:48 +00:00
parent 43739633b8
commit 3a493c1485
4 changed files with 246 additions and 17 deletions

25
enemy.hpp Normal file
View file

@ -0,0 +1,25 @@
#pragma once
#include <SFML/Graphics.hpp>
class Enemy {
private:
sf::RectangleShape shape;
float leftBound;
float rightBound;
float speed;
bool movingRight;
bool aggro;
float platformY;
public:
Enemy(float x, float y, float leftB, float rightB);
void update(float dt, const sf::Vector2f& playerPos);
void draw(sf::RenderWindow& window);
void setAggro(bool value);
float getPlatformY() const;
sf::FloatRect getBounds() const;
sf::RectangleShape& getShape();
};