YAPOG  0.0.1
Yet Another Pokemon Online Game
Sprite.hpp
Go to the documentation of this file.
1 #ifndef YAPOG_SPRITE_HPP
2 # define YAPOG_SPRITE_HPP
3 
4 # include "YAPOG/Macros.hpp"
7 
8 namespace yap
9 {
11  class YAPOG_LIB Sprite : public BaseSprite
12  {
14 
15  public:
16 
17  Sprite ();
18  explicit Sprite (Texture* texture);
19  explicit Sprite (const String& textureName);
20  Sprite (
21  const String& textureName,
22  const sf::IntRect& textureRect);
23  virtual ~Sprite ();
24 
25  void SetTexture (Texture* texture);
26 
29  virtual Sprite* Clone () const;
31 
32  protected:
33 
34  Sprite (const Sprite& copy);
35 
36  private:
37 
38  virtual void HandleMove (const Vector2& offset);
39  virtual void HandleScale (const Vector2& factor);
40 
41  virtual void HandleDraw (IDrawingContext& context);
42 
43  virtual void HandleShow (bool isVisible);
44  virtual void HandleChangeColor (const sf::Color& color);
45 
46  virtual void HandleUpdate (const Time& dt);
47 
48  Vector2 HandleGetSize () const;
49 
51  };
52 } // namespace yap
53 
54 #endif // YAPOG_SPRITE_HPP