Skip to content

Commit

Permalink
Use sf::Vector2<T> conversion constructor
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisThrasher committed Dec 12, 2023
1 parent ea9a9f1 commit 6bd9592
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions examples/cocoa/CocoaAppDelegate.mm
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,7 @@

sprite.setOrigin(sprite.getLocalBounds().getCenter());
sprite.scale({0.3f, 0.3f});

unsigned int ww = renderWindow.getSize().x;
unsigned int wh = renderWindow.getSize().y;
sprite.setPosition(sf::Vector2f(ww, wh) / 2.f);
sprite.setPosition(sf::Vector2f(renderWindow.getSize()) / 2.f);

if (!font.loadFromFile(resPath / "tuffy.ttf"))
NSLog(@"Couldn't load the font");
Expand Down

0 comments on commit 6bd9592

Please sign in to comment.