Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

string.sub() doesn't detect some characters?

Asked by 4 years ago

when I try to use string.sub() it doesn't detect some of the characters/letters that i use is there a solution?

print(string.sub("?????",1,1))

?
1
when you say string.sub("?????",1,1) you are getting the string from the 1st position to the 1st position (the first question mark in the string) If I did string.sub("abc",1,1) i would get "a". If I did string.sub("abcdef",1,3) i would get abc  royaltoe 5144 — 4y
1
What are you trying to do? If you are trying to get each character, do string.split("?????", ""). it will return a table containing every question mark in the string royaltoe 5144 — 4y
0
i didn't notice when posting but you can't upload some characters on this website either banane1man 2 — 4y
0
for text box's you can do print(script.Parent.Text:sub(1,1)) ROBLOXKING_MASTER1 0 — 3y

Answer this question