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

How could i make my gui not appear after a choose ?

Asked by
Zypsoh 25
5 years ago

Hi i have a choose morph gui to be a girl or a man and i need help to after a player choose what he want to be the menu don't appear anymore for him

Open script

local Frame = script.Parent.Parent.Parent.Frame

function onButtonClicked()
for i,v in pairs(script.Parent.Parent.Parent:children()) do
v.Visible = true
end
end
script.Parent.MouseButton1Down:connect(onButtonClicked)

Man choose

script.Parent.MouseButton1Click:Connect(function()
    game.ReplicatedStorage.ChangeChar:FireServer(game.ReplicatedStorage.Man)

end)

Girl choose

script.Parent.MouseButton1Click:Connect(function()
    game.ReplicatedStorage.ChangeChar:FireServer(game.ReplicatedStorage.Girl)

end)

My discord:Zypsoh#8546

2 answers

Log in to vote
0
Answered by
D3VRO 66
5 years ago

I assume all you would have to do is set the frame visibility to false once the player has clicked the button.

Ex:

script.Parent.MouseButton1Click:Connect(function()
    game.ReplicatedStorage.ChangeChar:FireServer(game.ReplicatedStorage.Man)
    Frame.Visible = false
end)
0
Yes but when he rejoin the button gonna come back... Zypsoh 25 — 5y
0
There is a setting in screenGUI called ResetOnSpawn. Turn it off. proo34 41 — 5y
Ad
Log in to vote
0
Answered by 5 years ago

You will need to use dataStores, which is server sided so you will need script and RemoteEvent to do so

Answer this question