Load the font you were asked to.
This commit is contained in:
parent
cce98514a7
commit
95f8f075db
1 changed files with 1 additions and 1 deletions
|
@ -190,7 +190,7 @@ sf::Texture Canvas::loadTexture(std::string_view path) {
|
||||||
|
|
||||||
sf::Font Canvas::loadFont(std::string_view path) {
|
sf::Font Canvas::loadFont(std::string_view path) {
|
||||||
sf::Font font;
|
sf::Font font;
|
||||||
if (!font.loadFromFile("retro_font.ttf")) {
|
if (!font.loadFromFile(std::string{ path })) {
|
||||||
exitFailure(fmt::format("Failed to load font {}", path));
|
exitFailure(fmt::format("Failed to load font {}", path));
|
||||||
}
|
}
|
||||||
return font;
|
return font;
|
||||||
|
|
Loading…
Reference in a new issue