Remote Event "Argument Missing or Nil"

I am trying to have a remote event fire an event that will make a gui visible.

The issue is that it gives an error saying “Argument Missing Or Nil”

local part = script.Parent
local frameVisible = game.ReplicatedStorage.frameVisible

part.ClickDetector.MouseClick:Connect(function()
	frameVisible:FireClient()
end)

you have to specify which client you are firing the remote to with the first argument.

If you want to fire to all the clients you can use
FireAllClients()

2 Likes

How do I specify which client? I want to fire to the localPlayer that clicks not every player.

use the player that gets passed

part.ClickDetector.MouseClick:Connect(function(player) -- the player that clicks gets passed
	frameVisible:FireClient(player)
end)
2 Likes

Awesome. Thank you so much!! I am very happy of you helping me.

1 Like