How would i make the players name show before this text?

Hey Everyone, I’m currently stuck on this bit of code; in the script i need the character to say the players name and then say the text, if you know how to do this i would greatly appreciate it!


The Players Name Would Go Before “it’s not raining yet, so we’re staying out longer!”

(this is also my first time posting on the Devforum so sorry if i mess something up.)

define the player ,then do something like this
player.Name . . “yourtexthere”

1 Like

Try this code when it says “It’s not raiding yet, so we’re staying out longer!”

TogglePlayerEvent:FireAllClients(false)
wait()
ToggleLesterEvent:FireAllClients(true)
for _, loopPlayer in pairs(game:GetService('Players'):GetPlayers()) do
   ChangeLesterDialogueEvent(loopPlayer, loopPlayer.Name .. " it's not raining yet, so we're staying out longer!")
end

Replace the original part after the wait(5) with the script above. I hope it helps!

It Kind Of Break Upon Adding This Part


did i add it in the wrong place?

i have also tried removing this part and i can’t get my game to work anymore, broken?

I messed that up sorry. It was a type :stuck_out_tongue:

Here is the fixed script:

TogglePlayerEvent:FireAllClients(false)
wait()
ToggleLesterEvent:FireAllClients(true)
for _, loopPlayer in pairs(game:GetService('Players'):GetPlayers()) do
   ChangeLesterDialogueEvent:FireClient(loopPlayer, loopPlayer.Name .. " it's not raining yet, so we're staying out longer!")
end