I wish for insert wish
how would I make it check if the text begins
with “I wish for”?
and then take off I wish for and split the text after
Dont really use the string function that much lol.
I wish for insert wish
how would I make it check if the text begins
with “I wish for”?
and then take off I wish for and split the text after
Dont really use the string function that much lol.
local split = string.split("full text", " ")
split[1] = "full"
split[2] = "text"
Or you could use:
if string.match(msg, "I wish for") then
print("is a wish")
end
You can use string.sub and string.split to do that for example:
local testString = "I wish for robux"
if string.sub(testString, 1, 10) == "I wish for" then
wishText = string.split(string.sub(testString, 12))
end
print(wishText) -- Will be equals to {"robux"}