I want the letters to form 1 by 1 to make seem as if it's being typed. I stumbled upon an error with my script showing numbers in-between each. I feel like I should know how to fix it but I'm stuck. Here's my script (Not Local) :
SP = script.Parent while true do SP.Text = "H"..wait(0.1).. "e"..wait(0.1).."l"..wait(0.1).."l"..wait(0.1).."o" wait(2) end
Thank you(This script is not finished, I'll be having more words show that's why it's so small). Oh, it is set as ScreenGui>Frame>TextLabel>script
Your problem here is that you are concatenating the return of wait
, which happens to be a number.
Your script also isn't very scaleable, since you're trying to write all the numbers by hand. Here's a more easily extendable form, using some string manipulation:
local sp = script.Parent function guiType(word) if string.len(word) <= 1 then sp.Text = word return end for i = 1, string.len(word) do sp.Text = string.sub(word, 1, i) wait(.1) end end local words = {"Hello.", "How are you?"} while true do guiType(words[1]) wait(2) guiType(words[2]) wait(2) end