EquipTools doesn't working

  1. I wanna equip tool to player by server side

  2. it doesn’t equip

local item = ReplicatedStorage.Assets.Weapon:FindFirstChild(Mouse.Target.Parent.ItemValue.Value)
		local model = Mouse.Target
		
		EquipItem:FireServer(model, item)


function Equip(LocalPlayer, model, item)
	LocalPlayer.Character.Humanoid:EquipTool(item)
end

EquipItem.OnServerEvent:Connect(function(LocalPlayer, model, item) 
Equip(LocalPlayer, model, item) 
end)

Is this just the client side?

What happens on the server?

Have you tried printing the variables to see if any are nil?

have you tried to do item.Parent = plr.Character

this sets the tool to players character

heres a example

Hey there, sorry for a late response, to my understanding these are 2 different scripts? if not be sure to handle equipping on the server side, otherwise the player will just hold his hand out. Also, EquipTool may be unneccassary, because when a player equips a tool it automatically goes into their character model, so just setting item.Parent = LocalCharacter.Character, Also is there a purpose of not just passing localplayer.character in the OnServerRecieved function? I currently handle equipping tools with this line item:Clone().Parent = plr.Character. Please let me know if this helps at all

Just saw the video, you could try adding a repeat task.wait() until character:WaitForChild(“Humanoid”) or something, so it ensures the character is loaded in the game before trying to add the sword, otherwise the character may be returning nil

It works but, the tool has to be in the backpack to start with.
A workaround …

EquipItem.OnServerEvent:Connect(function(LocalPlayer, model, item)
    if item:IsA("Tool") then
        item.Parent = LocalPlayer.Backpack
        LocalPlayer.Character.Humanoid:EquipTool(item)
    end
end)