Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

my gui does cant be seen by the playing player?

so i am calling a function when the button is clicked and that works its just the the gui is not visible to the playing player it works while im still in studio but as soon as i go into test it just wont be visible

here is my script:

local Question = game.StarterGui.Traitorgui.yesORno
script.Parent.TextButton.MouseButton1Click:Connect(function() -- If button is clicked
	Question.Visible = true
end)

just to show that the script works! it has been tested and the button and the clickdetector works títs something wrong with the gui and i do not know what!

the gui contains:

ScreenGui (not named that) Frame (Not named that) CornerUI, TextButton(not named that) TextButton(not named that), The LocalScript, textlabel x2 CornerUI CornerUI

1 answer

✓ Accepted answer

Upon the player spawn the gui is copied from StarterGui to PlayerGui (in player) (which is client side) the StarterGui is not linked with PlayerGui so if anything changes in StarterGui it dosen't change in PlayerGui the results only can be seen when player resets, then the StarterGui is copied again

--I could've mispelled smth but you should be able to correct it
local Question = game.players.LocalPlayer.PlayerGui.Traitorgui.yesORno
script.Parent.TextButton.MouseButton1Click:Connect(function() -- If button is clicked
    Question.Visible = true
end)

1 comment

0

TYSM bro

This discussion is preserved as it was. New answers, comments, and votes are closed.