A couple of things to list right off the bat:
1. StarterGui is a service and not a member of game.Workspace
2. The version of the ScreenGui that you are referencing in StarterGui will not be changed. No players have direct access to the version in StarterGui. The correct method would be accessing the GUI from the Player's PlayerGui folder (a child of the Player instance in "Players" service)
LocalScript:
local textButton = script.Parent
local Player = game:GetService("Players").LocalPlayer
local textLabel = Player.PlayerGui.MenuGui.Frame.TextButton.textLabel
textButton.MouseButton1Click:Connect(function()
textLabel.Visible = true
end)
I would also recommend doing checks to make sure each element you are referencing actually exists to prevent nil errors.
1 comment
Technically speaking, it doesn't have multiple parents. It has multiple ancestors.