Remove Point2f, replace with Vector2f

This commit is contained in:
Bram Verhulst
2024-04-17 13:54:48 +02:00
parent 64e96ab209
commit db83ae5e13
42 changed files with 494 additions and 634 deletions

View File

@@ -95,21 +95,21 @@ class WorldTile
{
public:
WorldTile() = default;
WorldTile(const Point2f& position, GroundTileType* groundTileType, TextureManager* pTextureManager, WorldGridManager* pGridManager);
WorldTile(const Vector2f& position, GroundTileType* groundTileType, TextureManager* pTextureManager, WorldGridManager* pGridManager);
~WorldTile();
void Draw();
void Update(Camera* camera); //TODO: no use
Point2f GetPosition() const {
Vector2f GetPosition() const {
return m_Position;
}
void SetPosition(const Point2f& position) {
void SetPosition(const Vector2f& position) {
m_Position = position;
}
Point2f GetSize() const {
return Point2f { 50, 50 };
Vector2f GetSize() const {
return Vector2f { 50, 50 };
}
GroundTileType * GetTileType() const {
@@ -124,7 +124,7 @@ public:
bool m_Hightlight { false };
private:
Point2f m_Position;
Vector2f m_Position;
GroundTileType* m_GroundTileType;
Texture* m_pTexture;