I made a script to show a GUI keypad in a project. the problem is that the GUI doesn’t appear. I noticed tht the gui only appears in the server client. Can anyone help me?
I use this script to show the gui
local Click = script.Parent:WaitForChild("ClickDetector")
Click.MouseClick:Connect(function(Plyr)
print(132134)
game.StarterGui.Echo12Keypad.Keypad.Visible = true
end)
Im confused by what you mean by this, Do you want others to be able to see the gui that pops up?
If so you need to add a remote event, when they click fire the event. Have another script that sees when the remote event was fired and then performs the action (Making the gui visible)
Im not good at scripting but i think you need to add a remote event and paste it into a replicated storage (you can put it anywhere you want thats just example) and then when you click it will :FireClient
Heres script:
local event = game.ReplicatedStorage.RemoteEvent -- put the way to event
local Click = script.Parent:WaitForChild("ClickDetector")
Click.MouseClick:Connect(function(Plyr)
print(132134)
event:FireClient()
Heres local script - put it into StarterGui or something
local event = game.ReplicatedStorage.RemoteEvent -- put the way to event
local playergui = game.Players.LocalPlayer.PlayerGui
event.OnClientEvent:Connect(function()
playergui.Echo12Keypad.Keypad.Visible = true
end)