ashes999 Posted October 8, 2014 Share Posted October 8, 2014 Following the usual nine-part Phaser tutorial on making a platformer, I see code like:scoreText = game.add.text(16, 16, 'score: 0', { fontSize: '32px', fill: '#000' });Changing the fontSize property doesn't do anything. I tried multiple values (8px, 72px, etc.) as well as different types ('72px', '72pt', '72', 72, etc.) -- all to no avail. Am I doing something wrong? Link to comment Share on other sites More sharing options...
space_elevators Posted October 9, 2014 Share Posted October 9, 2014 I bookmarked the Phaser docs on text styles and refer to them frequently - take a look here: http://docs.phaser.io/Phaser.Text.html#setStyle What you're looking for is the font property - so your code should look like:scoreText = game.add.text(16, 16, 'score: 0', { font: '32pt Arial', fill: '#000' });(assuming you want to use Arial ) Link to comment Share on other sites More sharing options...
ashes999 Posted October 9, 2014 Author Share Posted October 9, 2014 You are awesome. Thanks very much! Link to comment Share on other sites More sharing options...
Recommended Posts