mirror of
https://github.com/SFML/SFML.git
synced 2024-11-25 04:41:05 +08:00
Use sf::Vector2<T>
conversion constructor
This commit is contained in:
parent
ffe9cc0671
commit
3d4ea00135
@ -49,10 +49,7 @@ struct SFMLmainWindow
|
|||||||
|
|
||||||
sprite.setOrigin(sprite.getLocalBounds().getCenter());
|
sprite.setOrigin(sprite.getLocalBounds().getCenter());
|
||||||
sprite.scale({0.3f, 0.3f});
|
sprite.scale({0.3f, 0.3f});
|
||||||
|
sprite.setPosition(sf::Vector2f(renderWindow.getSize()) / 2.f);
|
||||||
unsigned int ww = renderWindow.getSize().x;
|
|
||||||
unsigned int wh = renderWindow.getSize().y;
|
|
||||||
sprite.setPosition(sf::Vector2f(ww, wh) / 2.f);
|
|
||||||
|
|
||||||
if (!font.loadFromFile(resPath / "tuffy.ttf"))
|
if (!font.loadFromFile(resPath / "tuffy.ttf"))
|
||||||
NSLog(@"Couldn't load the font");
|
NSLog(@"Couldn't load the font");
|
||||||
|
Loading…
Reference in New Issue
Block a user