Rich Text Markup doesnt work before Typewriter Effect happens

I want to apply a different color to a part of text before it shows up through a typewriter effect. When I try to do this, the effect only appears after its been written by the typewriter. Heres a video:

I’ve tried looking everywhere but have found nothing.

Heres the script:

local Narrator = script.Parent –TextLabel

local function typewrite(object, text, length)
for i = 1,#text,1 do
object.Text = string.sub(text,1,i)
wait(length)
end
end

wait(4)
typewrite(Narrator, “Oh! Its a new soul…”, 0.1)
wait(2.5)

This other post has the solution

2 Likes