Hello, I am trying to make a script were a player can equip a trident, but its not working, here is the code that the error is from
local tridentc = trident:Clone() tridentc.Parent = player.Backpack tridentc.Name = "Trident1" character.Humanoid.EquipTool(tridentc)
I keep on getting an error that says
** 2:07:21.324 - The function EquipTool is not a member of "Tool" **
what did I do wrong?
The issue you are having is that you're trying to use a . instead of a :
Therefore what you should do is
local clone = trident:Clone() clone.Name = 'Trident1' clone.Parent = player.Backpack character.Humanoid:EquipTool(clone)
This should work perfectly now. But I should add Mc3334 is correct, if you'd like it to just be automatically equipped. Setting the clones parent to the player.Character may be a bit more beneficial.
But yeah that was your issue :)
To get your results, you could clone the tool under the player's character. It would look something like this.
local tridentc = trident:Clone() tridentc.Parent = player.Character --I changed the "Backpack" to "Character" so it will equip the tool tridentc.Name = "Trident1"
I hope this was helpful. If you need further help regarding this topic, feel free to comment on my post.