Tool equipped RemoteEvent

So, i want to learn how to use RemoteEvent with Tool.Equipped but the Player arg. isn’t being taked as a Player.

Can you show us your code? We can’t help you if we do not know what your attempting to do.

Explorer

ClientFunction

local Equipped = game.ReplicatedStorage.Door.Equipped
local Unequipped = game.ReplicatedStorage.Door.Unequipped

Equipped.OnClientEvent:Connect(function(Player)
	game.Workspace.Door.Transparency = .5
	game.Workspace.Door.CanCollide = false
end)

Unequipped.OnClientEvent:Connect(function(Player)
	game.Workspace.Door.Transparency = 0
	game.Workspace.Door.CanCollide = true
end)

ServerFunction

local Equipped = game.ReplicatedStorage.Door.Equipped
local Unequipped = game.ReplicatedStorage.Door.Unequipped

script.Parent.Equipped:Connect(function(Player)
	Equipped:FireClient(Player.Name)
end)
script.Parent.Unequipped:Connect(function(Player)
	Unequipped:FireClient(Player.Name)
end)

Ok so I believe I know the issue.

Your trying to fire to the client of someone but you are not selecting who you would like to fire it to.

When using the :FireClient it requires one Parameters and then can if you want some arguments to send to the client… The first one is the user who you wants it to fire the event to and then the second one or the other ones are the stuff you want to send over as stated in the documents.

RemoteEvent:FireClient (roblox.com)

What your doing is sending the arguments which you would like to pass to the client but not who you would like to aim it to.

If you want to fire the event to everyone then just do the :FireAllClients which only needs your arguments you want to sent to all of the clients inside of the server.

RemoteEvent:FireAllClients (roblox.com)

Just to fix it for you quick here is what you need to do on your server code instead.

Server Code:

local Equipped = game.ReplicatedStorage.Door.Equipped
local Unequipped = game.ReplicatedStorage.Door.Unequipped

script.Parent.Equipped:Connect(function(Player)
	Equipped:FireClient(Player, Player.Name)
end)
script.Parent.Unequipped:Connect(function(Player)
	Unequipped:FireClient(Player, Player.Name)
end)