Text linespacing broken as of version 3.18

Hello!

I’ve been trying to upgrade the version of Phaser I’m using and I noticed that a change between versions 3.17 and 3.18 appears to have broken the text linespacing.

You can see even the demo doesn’t work correctly (at least on Chrome):

This one works properly:
https://labs.phaser.io/edit.html?src=src/game%20objects/text/static/line%20spacing.js&v=3.17.0

This one does not:
https://labs.phaser.io/edit.html?src=src/game%20objects/text/static/line%20spacing.js&v=3.18.0

Does anyone have any advice on a fix by chance?

Thanks!
Scott

Hey Scott, use this: text.setLineSpacing(LINE_SPACING)

Jake,

Thanks! You’re right. That works. I wonder why it works setting it after the fact but not in the initial properties?

Appreciate the work-around.

There are some funky behaviours with text. if you have a strokeThickness in quotes, ex: ‘3’ and set the origin of the text, it will throw it way off and line spacing is also effected by this, but if you remove the quotes it acts as expected.