YAPOG  0.0.1
Yet Another Pokemon Online Game
ISpatial.hpp
Go to the documentation of this file.
1 #ifndef YAPOG_ISPATIAL_HPP
2 # define YAPOG_ISPATIAL_HPP
3 
4 # include <SFML/Graphics/Rect.hpp>
5 
6 # include "YAPOG/Macros.hpp"
8 
9 namespace yap
10 {
12  struct ISpatial
13  {
14  virtual ~ISpatial () { }
15 
20  virtual const Vector2& GetPosition () const = 0;
23  virtual const Vector2& GetSize () const = 0;
24 
25  virtual const Vector2& GetTopLeft () const = 0;
26  virtual const Vector2& GetBottomRight () const = 0;
27  virtual const Vector2& GetCenter () const = 0;
28 
29  virtual const sf::FloatRect& GetRectangle () const = 0;
30 
31  virtual void Move (const Vector2& offset) = 0;
32  virtual void Scale (const Vector2& factor) = 0;
33 
34  virtual void SetPosition (const Vector2& position) = 0;
35  virtual void SetSize (const Vector2& size) = 0;
36  };
37 } // namespace yap
38 
39 #endif // YAPOG_ISPATIAL_HPP