RType
maintestdisplay.hpp
Go to the documentation of this file.
1 #ifndef MAINTESTDISPLAY_HPP
2 #define MAINTESTDISPLAY_HPP
3 
4 #include <SFML/Graphics.hpp>
5 #include <iostream>
6 
7 class Sprite
8 {
9  public:
10  Sprite(std::string path, int animationLimit = 0);
11  ~Sprite() = default;
12  void animateSprite(int frameCount, int frameToBegin, int numberFrameToAnim, float switchTime, int top, int bottom,
13  sf::Clock clock, sf::RenderWindow &window);
14  void drawSprite(sf::RenderWindow &window)
15  {
16  window.draw(_Sprite);
17  };
18  int getSizeY()
19  {
20  return _Texture.getSize().y;
21  };
22  int getSizeX()
23  {
24  return _Texture.getSize().x;
25  };
26 
29 
30  protected:
34 };
35 
36 #endif // MAINTESTDISPLAY_HPP