Quantcast
Channel: Indigo Rose Software Forums - Forums
Viewing all articles
Browse latest Browse all 2105

How to make a command ignore a specific part of a label?

$
0
0
Let's say the following script is:
local text = Label.GetText("Label1")
if text == "creeper?" then
Label.SetText("Label2", "aw maaan")
elseif text == "" then
Label.SetText("Label2", "will ya type sum or just remain silent?")
elseif text == "hi" then
Label.SetText("Label2", "hola bruh")
elseif text == "so we're back in the mine" then
Label.SetText("Label2", "sorry i don't remember the rest of it lol")
elseif text == "frick" then
Label.SetText("Label2", "hey it's a ****en christian server don't SWEAR!")
end
Let's say this script embeds a specific text when you type something in an input and press enter. The problem is, this script takes the whole sentence, like: when the script sees Label1 saying "creeper" it should say "aw maaan" the problem is, in Label1 there's a text in it that i essentially need, called "Guest1: " the problem here is if Label1 says "Guest1: creeper" it does not work because Guest1 exists in the label, i need this script to ignore the existance of "Guest1" so it'd be able to say "aw maaan" even if there's guest1 in the text.
Thanks.

Viewing all articles
Browse latest Browse all 2105

Trending Articles