Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #ifndef ENTITY_HPP
- #define ENTITY_HPP
- namespace Alice
- {
- class Entity
- {
- private:
- /* Приватные поля */
- sf::Texture _texture;
- sf::Sprite _sprite;
- std::string _name;
- sf::Vector2i _position;
- sf::Vector2i _size;
- sf::Vector2i _hitboxSize;
- float _speed;
- float _timeStep;
- public:
- /* Конструктор-деструктор */
- Entity();
- Entity(std::string filePath);
- /* Сеттеры */
- void SetTexture(std::string filePath);
- void SetName(std::string name);
- void SetPosition(sf::Vector2i position);
- void SetSize(sf::Vector2i size);
- void SetHitboxSize(sf::Vector2i hitboxSize);
- void SetSpeed(float speed);
- void SetTimeSteep(float timeStep);
- /* Геттеры */
- sf::Sprite GetTexture(void);
- std::string GetName(void);
- sf::Vector2i GetPosition(void);
- sf::Vector2i GetSize(void);
- sf::Vector2i GetHitboxSize(void);
- float GetSpeed(void);
- float GetTimeSteep(void);
- /* Логика */
- void Update(void);
- void Draw(void);
- virtual void UserEvent(void);
- };
- }
- #endif //!ENTITY_HPP
Add Comment
Please, Sign In to add comment