Font preloading doesn't work

Hello! I’m unable to preload fonts for some reason, particularly Amatic SC:

ContentProvider:PreloadAsync({ "rbxasset://fonts/families/AmaticSC.json" }, function(assetId, state)
    print(state) -- Failure
end)

can simply set fonts like

TextLabel = script.Parent 
TextLabel.Font = Enum.Font.AmaticSC

Preloading exists for a reason…

what you need even just preload font or what?

I want to preload font, because I have a typewriter effect that flickers because font loads after the effect has started.

fonts dont need to be loaded you need only load effects, images…
numbers, strings, fonts dont need to be loaded
if you want to load font user doing this for you you can simply just add loading screen

But how do you think loading screens work!?

it can be simple wait random time enough to load all objects

That’s not how good scripting works. What if it takes more time to load things?

if you game have parts or any objects you can just loop through each.

can you show us the typewriting script? it should only take time for the font to load the first time it’s shown, after that it’s cached and should loads instantly, so there’s a chance you’re doing something wrong when creating the effect.

I’m not doing anything wrong, it is cached. But I want to preload it so that it doesn’t change from default font to specified mid-animation. That happens because I use <font> tag inside rich text label.

1 Like

I’m not sure preload is what you want to use then. Preload is meant to be used on instances (you can also input the id but my point still stands), roblox will then determine what needs to be loaded and yield until they are loaded. Since the font is already loaded I can’t really help unless you can show me how your typewriter effect works

1 Like