well as the tittle says, i cant use a Open-Bracket in String, but i really need it.
the question is, it has a way to get the expected result?
Ah and yea, a Close-Bracket is possible to use. (as the underline shows)
well as the tittle says, i cant use a Open-Bracket in String, but i really need it.
the question is, it has a way to get the expected result?
Ah and yea, a Close-Bracket is possible to use. (as the underline shows)
Try making β[β another variable, something like this (and run the code and see if it works)
local openBracket = "["
local startBracket = string.find(Dsc, openBracket)
local endBracket = string.find(Dsc, "]")
hmm got it, it worked but now i have anoother problem
but i can solve it alone, thanks!
The reason it isnβt letting you do it is because [ is treated as a special character.
The way to put the special character into the string without the error occuring is the put an escape character (which is typically a backslash, however Roblox uses % for this) before the character.
i.e.
string.find(Dsc, "%[")
Using a seperate variable, as the other person suggested, does work but itβs just a bit clunky and unneccessary.
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.