I'm trying to make welcome GUI? I guess and I tried
(I'm using a Local Script in a GUI)
1 | --Variabls-- |
2 | local user = game.Players.LocalPlayer |
3 | local message = script.Parent.TextLabel |
4 | --Scripts-- |
5 | message.Text = ( "Welcome, " user) |
and
1 | --Variabls-- |
2 | local user = game.Players.LocalPlayer |
3 | local message = script.Parent.TextLabel |
4 | --Scripts-- |
5 | message.Text = ( "Welcome, " , user) |
and this
1 | --Variabls-- |
2 | local user = game.Players.LocalPlayer |
3 | local message = script.Parent.TextLabel |
4 | --Scripts-- |
5 | message.Text = ( "Welcome, " ,user) |
can anyone help me?
I believe you are trying to concatenate here in your local script,
To concatenate use dots like this:
1 | local message = script.Parent.TextLabel |
2 | message.Text = "Welcome, " ..(stringvalue) |
You are also trying to concatenate using only the player, you must use the name property of it as it returns a string value (text), completing it as:
1 | local user = game.Players.LocalPlayer |
2 | local message = script.Parent.TextLabel |
3 | message.Text = "Welcome, " ..user.Name |
I think you should reference the player's Name
instead of the player itself.
1 | local user = game.Players.LocalPlayer |
2 | local message = script.Parent.TextLabel |
3 |
4 | message.Text = ( "Welcome, " , user.Name) |
Hope it works.