I'm trying to do a draft for a league and I want to be able to edit the GUI in-game, so for instance say I have a board and a player gets drafted I want to be able to change the GUI text at the moment inside the game, so it would switch from "Player" to the players name. I have a good example however I can't post links. How can I do this?
COMMUNITY QUESTION
How do I make a GUI text change within the game?
1 answer
You simply need to set the text property of the TextLabel within the Gui where you want the player's name to show up. For example:
local player = game:GetService("Players").LocalPlayer
player.PlayerGui.ExampleGui.ExampleLabel.Text = "Hello." --Will set the example label under the example gui to Hello.
Text can be set to anything as long as it's a string or a number. All you'll need to do is grab the player and utilize their name.
This discussion is preserved as it was. New answers, comments, and votes are closed.
