1
0
forked from noxious/client

Also apply text offset fix for Android

This commit is contained in:
Dennis Postma 2024-10-01 00:48:55 +02:00
parent e5213cf5e6
commit 7a50385420

View File

@ -139,8 +139,8 @@ const createChatText = (text: Phaser.GameObjects.Text) => {
text.setFontSize(13)
text.setFontFamily('Arial')
// Fix text alignment on Windows
if (game.device.os.windows) {
// Fix text alignment on Windows and Android
if (game.device.os.windows || game.device.os.android) {
text.setOrigin(0.5, 9.75)
}
}
@ -149,8 +149,8 @@ const createText = (text: Phaser.GameObjects.Text) => {
text.setFontSize(13)
text.setFontFamily('Arial')
// Fix text alignment on Windows
if (game.device.os.windows) {
// Fix text alignment on Windows and Android
if (game.device.os.windows || game.device.os.android) {
text.setOrigin(0.5, 8)
}
}