Answered by
5 years ago Edited 5 years ago
This will happen everytime the player respawns, they'll start from the beginning if they die.
01 | game.Players.PlayerAdded:Connect( function (player) |
02 | player.CharacterAdded:Connect( function (Character) |
03 | Character.Humanoid.WalkSpeed = 0 |
04 | local PlayerGui = player:WaitForChild( "PlayerGui" ) |
05 | local ScreenGui = PlayerGui:WaitForChild( "ScreenGui" ) |
06 | local infoLabel = ScreenGui:WaitForChild( "infoLabel" ) |
07 | infoLabel.Text = "Welcome to Player Experiments." |
09 | infoLabel.Text = "Lets start with your username." |
11 | infoLabel.Text = "Your username is " .. player.Name.. ". Right?" |
If you didn't want that then here, it'll only play the beginning part once:
01 | game.Players.PlayerAdded:Connect( function (player) |
02 | player.CharacterAdded:Wait() |
03 | player.Character.Humanoid.WalkSpeed = 0 |
04 | local PlayerGui = player:WaitForChild( "PlayerGui" ) |
05 | local ScreenGui = PlayerGui:WaitForChild( "ScreenGui" ) |
06 | local infoLabel = ScreenGui:WaitForChild( "infoLabel" ) |
07 | infoLabel.Text = "Welcome to Player Experiments." |
09 | infoLabel.Text = "Lets start with your username." |
11 | infoLabel.Text = "Your username is " .. player.Name.. ". Right?" |