I’m building an old school arcade shooter as a first project with BabylonJS and loving it. I have an issue using my font in the Babylon GUI.
I’ve read all the posts here on loading fonts and I can use any font other than the one I want.
Here’s a playground with the issue. I can’t get the font “Press Start 2P” to work in the GUI.
Hi @Viperfish !
I am not quite sure but I think it’s an issue with the font itself. A quick solution might be to put it in quotes like this:
loadFont("‘Press Start 2P’", 120);
so it will display in the playground! Console still throws some errors though…
A quick google trip brought me to this thread which may help you with your further investigations:
Thanks for the quick response. Adding the extra quotation marks loads the font. Strange. But it works. Thank you.
Doesn’t feel strange to me. The reason is because the font name as spaces. It would do the same with just HTML/css. The quotes just set the limit for the font name.