Jump to content

Loading font on an unstable connection


Recommended Posts

Hello everyone,

I'm trying to handle a very specific case. I have custom loader logic which handles the loss of internet connection and retries the loading of game resources a few times before giving up. This works great for most types of assets except BitMapFonts. The .fnt files that are used to load in the fonts reference the corresponding font .png files. The problem is if your connection drops while the font .png files are loading, the BitMapFont loader will still try to create a font with the unloaded texture and start throwing errors.

I thought I might be able to handle this by loading the images separately from the fnt files and just providing a loaded texture to the BitMapFont loader, when the fnt file loads. Could I get some advice on how to best approach this? Has anyone dealt with a similar issue?


Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...