YAPOG
0.0.1
Yet Another Pokemon Online Game
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
SpatialInfo.hpp
Go to the documentation of this file.
1
#ifndef YAPOG_SPATIALINFO_HPP
2
# define YAPOG_SPATIALINFO_HPP
3
4
# include <SFML/Graphics/Rect.hpp>
5
6
# include "
YAPOG/Macros.hpp
"
7
# include "
YAPOG/Graphics/Vector2.hpp
"
8
9
namespace
yap
10
{
11
class
YAPOG_LIB
SpatialInfo
12
{
13
public
:
14
15
SpatialInfo
();
16
SpatialInfo
(
const
Vector2
& position,
const
Vector2
& size);
17
18
SpatialInfo
(
const
SpatialInfo
& copy);
19
SpatialInfo
& operator= (
const
SpatialInfo
& copy);
20
21
const
Vector2
& GetPosition ()
const
;
22
const
Vector2
& GetSize ()
const
;
23
24
const
Vector2
& GetTopLeft ()
const
;
25
const
Vector2
& GetBottomRight ()
const
;
26
const
Vector2
& GetCenter ()
const
;
27
28
const
FloatRect
& GetRectangle ()
const
;
29
30
void
SetPosition (
const
Vector2
& position);
31
void
SetSize (
const
Vector2
& size);
32
33
private
:
34
35
void
Init (
const
Vector2
& position,
const
Vector2
& size);
36
void
Update ();
37
38
Vector2
position_
;
39
Vector2
size_
;
40
41
Vector2
center_
;
42
Vector2
topLeft_
;
43
Vector2
bottomRight_
;
44
45
sf::FloatRect
rectangle_
;
46
};
47
}
// namespace yap
48
49
#endif // YAPOG_SPATIALINFO_HPP
YAPOG
include
YAPOG
Graphics
SpatialInfo.hpp
Generated on Mon Sep 17 2012 22:24:24 for YAPOG by
1.8.1.1