Home | Namespaces | Hierarchy | Alphabetical List | Class list | Files | Namespace Members | Class members | File members
E:/Programming/MyProject/K_Game_hg/GameEngine/include/core/Position2d.h
Go to the documentation of this file.
00001 // Copyright 2006-2011 by Kat'Oun
00002 
00003 #ifndef _POSITION_2D_H_
00004 #define _POSITION_2D_H_
00005 
00006 #include <EngineConfig.h>
00007 #include <core/Types.h>
00008 
00009 namespace core
00010 {
00011 
00013 class ENGINE_PUBLIC_EXPORT position2d
00014 {
00015 public:
00016 
00017         position2d();
00018         position2d(s32 x, s32 y);
00019         position2d(const position2d& other);
00020 
00021         inline position2d& operator=(const position2d& other);
00022 
00023         inline position2d operator-(const position2d& other) const;
00024         inline position2d& operator+=(const position2d& other);
00025 
00026         inline position2d operator+(const position2d& other) const;
00027         inline position2d& operator-=(const position2d& other);
00028 
00029         inline bool operator == (const position2d& other) const;
00030         inline bool operator != (const position2d& other) const;
00031 
00033         f32 getDistanceFrom(const position2d& other) const;
00034 
00036         f32 getDistanceFromSQ(const position2d& other) const;
00037 
00039         static const position2d ORIGIN_2D;
00040 
00041         s32 X, Y;
00042 };
00043 
00044 } // end namespace core
00045 
00046 #endif

The KG Game Engine
The KG Game Engine Documentation © 2006-2011 by Kat'Oun. Generated on Sat Jul 2 2011 00:50:04 by Doxygen (1.7.4)