These are chat archives for pixijs/pixi.js

25th
Oct 2017
@R_Talon_twitter
Oct 25 2017 06:59

Hello!! good morning!!! I have a problem with PIXI BitmapText and ShoeBox. I have a atlas with number ( 0 - 9 ) and TxtMonospace property TRUE in shoeBox. The problem is the textWidth in PIXI. Example.
text = 100 -> textWidth = 300
text = 101 -> textWidth = 280

Why??? My texture atlas font is with txtMonospace in ShoeBox. What happend?

the correct output should be the same textwidth
Ivan Popelyshev
@ivanpopelyshev
Oct 25 2017 08:52
the problem is that tools store fonts/spritesheets in slightly different formats
you have to look inside the file that was exported closely and look at how pixi loads it
@R_Talon_twitter
Oct 25 2017 08:53
yes, sure
Is there another program as shoebox?
Ivan Popelyshev
@ivanpopelyshev
Oct 25 2017 08:53
also make sure you are using latest version of pixi, it did have changes for BitmapText not so long ago
@R_Talon_twitter
Oct 25 2017 08:53
yes, 4.5.1
Ivan Popelyshev
@ivanpopelyshev
Oct 25 2017 08:53
I dont remember whatever is used for bitmap fonts and pixi )
you can take latest dev
pixijs.download/dev/pixi.js
bitmapfonts arent my expertise, you have to search BitmapText issues in pixi github and find people who solve that problems
i remember that there was a tool for libgdx for those fonts
@R_Talon_twitter
Oct 25 2017 08:56
ohhh, these sound good!
Ivan Popelyshev
@ivanpopelyshev
Oct 25 2017 08:56
as for shoebox - i had problems with shoebox spritesheets and format was slightly different so i had to adjust loading process
may be there's something like that with bitmapfont
@R_Talon_twitter
Oct 25 2017 08:56
I lloking for libgdx
Ivan Popelyshev
@ivanpopelyshev
Oct 25 2017 08:56
but what I know for sure - you'll have to read bitmapfont and bitmaptext sources anyway
@R_Talon_twitter
Oct 25 2017 08:56
yes yes
Ivan Popelyshev
@ivanpopelyshev
Oct 25 2017 08:56
regardless of what you choose
@R_Talon_twitter
Oct 25 2017 08:56
I going to test with libgdx
thanks you man!!!