(This is a repost, don't worry I deleted the original post)
local text = script.Parent.Text
local status = script.Parent.StatusValue.Value
if text ~= status then
for i = 1, string.len(status) do
text = string.sub(status, 1, i)
wait(0.04) --This is the speed of the text
end
end
Hello there, my problem is that the text isn't even appearing and the text that was originally there stays there. I've tried fixing this, and yet it isn't working and I have no idea as of why it isn't. I mean, I've gotten to the point of changing the status variable to camelCase cause I have no idea.
This is a script (I've tried changing it to a local script and it hasn't worked either) in a text label named "TextStatus" which also has a string value named "StatusValue" which will hold the status (text) that is supposed to be in the text variable in "TextStatus"
Thank you for reading this,
Narwhal
EDIT: I'm new to this "for i = 1, string.len(status) do" stuff, also "for i,v in pairs do" (sorry if I said it wrong), type stuff. also thanks for help RiskoZoSlovenska! '

2 comments
the error means that for the "for i=1, string.len(status)" line, "string.len(status)" cant be a limit because its a string, not a numbervalue. i consider translating the string to numbervalue so it can work.
sorry i forgot to get rid of that, that error was from the earlier script (this was edited from advie from RiskZoSlovenska)