Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Editor crash - BBText crash because of undefined style (reading 'fill') #6180

Open
VanCastar opened this issue Jan 11, 2024 · 3 comments
Open
Labels
💥crash Bug that is crashing the software

Comments

@VanCastar
Copy link

Describe what you were doing when the crash happened

I opened up The old and then working Miles Apart project.
Then this happened when trying to start the main scene.
Login etc worked fine but main menu scene was broken.
Last time I ran it via editor was in Feb 2023 as a working project and nothing has changed after that but GDevelop version.
I also tried to update all extensions but no change.

GDevelop version

5.3.186-0a6b0dc78508b65a61cf5bcad98827d8998a80e2

Platform info

System Version: 10.0.19045, Arch: x64, User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) GDevelop5/5.3.186 Chrome/100.0.4896.143 Electron/18.2.2 Safari/537.36, Platform: win32

Additional error context

uniqueErrorId: c9a8da99-e25b-4553-a094-5efae00e8fd9

TypeError: Cannot read properties of undefined (reading 'fill')
at h.getFontString (C:\Users\Ramiel\AppData\Local\Programs\GDevelop\resources\GDJS\Runtime\Extensions\BBText\pixi-multistyle-text\dist\pixi-multistyle-text.umd.js:1:4971)
at h.wordWrap (C:\Users\Ramiel\AppData\Local\Programs\GDevelop\resources\GDJS\Runtime\Extensions\BBText\pixi-multistyle-text\dist\pixi-multistyle-text.umd.js:1:11589)
at h.updateText (C:\Users\Ramiel\AppData\Local\Programs\GDevelop\resources\GDJS\Runtime\Extensions\BBText\pixi-multistyle-text\dist\pixi-multistyle-text.umd.js:1:5629)
at h.get (file...

Additional component context

in n
in t
in Unknown
in div
in div
in Unknown
in Measure
in mw
in Mw
in div
in div
in t
in div
in t
in n
in ForwardRef
in div
in l
in n
in n
in t
in Unknown
in QM
in div
in n
in oa
in div
in vO
in Unknown
in Qe
in f
in u
in v
in x
in j
in h
in h
in Z
in d
in Q
in n
in t
in xe
in n
in Ge
in tt
in t
in Unknown
in Unknown
in v
in ft
in t
in r
in n
in u
in l
in n
in Dr...
@ClementPasteau
Copy link
Collaborator

Thanks for reporting @VanCastar
It looks like an issue coming from the BBText, using the pixi package "pixi-multistyle-text" (which is now archived unfortunately)
Happens around this line https://github.com/tleunen/pixi-multistyle-text/blob/3a42873661533af916867f49917f47e764a26181/src/pixi-multistyle-text.ts#L395 though unsure which version we have in the project.

It could be because the upgrade of Pixi to 7 changed the interface of the TextStyle? Unsure.
Would you be able to share your zipped project with us so we can take a look?
Sharing it here or sending it via [email protected]

@ClementPasteau ClementPasteau changed the title Crash while using an editor Editor crash - BBText created on previous GDevelop versions crash because of undefined style (reading 'fill') Jan 18, 2024
@ClementPasteau ClementPasteau added the 💥crash Bug that is crashing the software label Jan 18, 2024
@ClementPasteau ClementPasteau changed the title Editor crash - BBText created on previous GDevelop versions crash because of undefined style (reading 'fill') Editor crash - BBText crash because of undefined style (reading 'fill') Jan 18, 2024
@VanCastar
Copy link
Author

Would you be able to share your zipped project with us so we can take a look? Sharing it here or sending it via [email protected]

Unfortunately no, as I don’t have that particular project anymore..

@ClementPasteau
Copy link
Collaborator

Had a similar issue recently so posting on this one to track the analysis.
Turns out we were wrongly doing a [color=255;255;255;] which cannot be parsed by the pixi-multistyle-text library. (it expects a #000000 color)

It is hard to prevent bad formatting directly in GDevelop, as the parsing of the text is done inside the library, so this error may happen again if the text used is not recognized by the library.

In conclusion, if someone has this problem again, check the text used for the BBText and ensure it matches the format suggested on the wiki page: https://wiki.gdevelop.io/gdevelop5/objects/bbtext/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
💥crash Bug that is crashing the software
Projects
None yet
Development

No branches or pull requests

2 participants