c7ef086d3d
This simplifies the rendering code and remove all(!) pointers. There is a number of unresolved issues * Windows build ? * position delta computation: migrating to SFML seems to have modified the frame rate.
21 lines
293 B
C++
21 lines
293 B
C++
#pragma once
|
|
|
|
#include <SFML/Graphics.hpp>
|
|
|
|
struct Position {
|
|
float x;
|
|
float y;
|
|
};
|
|
|
|
struct PositionInt {
|
|
int x;
|
|
int y;
|
|
};
|
|
|
|
using Rect = sf::Rect<int>;
|
|
|
|
using Sprite = sf::Sprite;
|
|
|
|
inline bool operator==(const PositionInt & b, const Position & a) {
|
|
return a.x == b.x && a.y == b.y;
|
|
}
|