Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

It won't concatenate the values together into a text label?

Asked by 6 years ago

So I have a part that when has something touching it, puts some data of the thing onto a text label but it prints this message.

16:15:10.677 - Players.TheArcticTerminal.Backpack.Info Tool.Screen.SurfaceGui.Frame.Script:7: attempt to concatenate field 'BrickColor' (a userdata value)

Here is my script.

WM.Text = ("Material:".. hit.Material .. "Transparency:".. hit.Transparency.. "Color".. hit.BrickColor)
    print("Material:".. hit.Material .. "Transparency:".. hit.Transparency.. "Color".. hit.BrickColor)

1 answer

Log in to vote
0
Answered by 6 years ago

try tostring(hit.BrickColor)

Ad

Answer this question