hi can someon teach me how to change text lable text by script
In order to change the text, you need to place a "StringValue" item inside ReplicatedStorage. Then, make this script inside of your textlabel.
game.ReplicatedStorage.StringValue.Changed:Connect(function() script.Parent.Text = game.ReplicatedStorage.StringValue.Value end
And, to change it in another script, simply do:
game.ReplicatedStorage.StringValue.Value = "Insert your text here"
How it works is that when the StringValue
has the value changed, it will fire a signal to the TextLabel
inside of your ScreenGui
or any other GuiObject
. Furthermore, when you change the StringValue
's value to something else, the script inside of your TextLabel
recieves your signal and changes it according to the StringValue
.
I hope I helped! Comment if it doesn't work, and also show me the script. Adios!