Alright, this script takes a target of a string and prints it out one by one, however, I'm getting an error and I'm not sure why.
Not working
MainDest = script.Parent.speechLabel String = "Why this no work.." function Speak(message, target) for i = 1, message:len() do wait() target.Text = message:Sub(1,i) end end wait(1) Speak(String, MainDest)
Error:
8: attempt to call method 'Sub' (a nil value)
Working without function
for i = 1, String:len() do wait() Message.Text = String:sub(1,i) end
Any help would be great! Thanks!
Its :sub not :Sub
That's the only error in your code