Im trying to make a death screen thing where when you die it chooses random text. Heres the string randomizer script i have
local RandomNumber = math.random(1,20)
local Responses = {
"Well, you died. That sucks, try again.",
"Stop dying! This is boring to watch!!",
"You didn't even survive.. lame..",
"What have you done",
"You'd still be alive if you got off that damn phone",
"Oof. Now you gotta do it all over again.",
"This is dissapointing.",
"If you die again, then you die. But I recommend you dont die.",
"I hope you learned from your mistake",
"You died for a reason, noob",
"Huh, something just stopped. Oh, it was your heart",
"Blame it on lag",
"hahaahahahahahhahahhahahahaha",
"Wow that was great! (said no one) ",
"Its fun to watch you continuously fail and fail",
"Your character infinetly falls into the void",
"Hey loser, you died",
"My dissapointment is immeasurable and my day is ruined",
"You had a good life. Until you pathetically died.",
"You died, but look on the bright side! You get infinite tries",}
local FinalMessage = (Responses[RandomNumber])
-so theres a variable that chooses a random number between 1 and 20 -a variable that is a table that has 20 different string values -a variable called FinalMessage which is the responses and the random number choosing a random value
so then i try this
game.StarterGui.DeathGui.Frame.TextLabel.Text = FinalMessage
the script is in ServerScriptStorage idk if that makes a difference
when it runs the text doesnt change so thats it.

1 comment
also when i print it, it works. It just wont change the value of the text though