How are you equipping the tool if it is in a folder in the workspace? You can only equip tools that are in your backpack, unless you are equipping it manually through a script. You may also want to add WaitForChild statements to ensure that everything has loaded in.
And there are no errors? Maybe try this to see if it registers it being equipped. I doubt this would be the problem but maybe if you are moving the tool to the players backpack with a local script then the server doesn’t realize that it is there, so it never registers the tool.Activated:
local tool = game.Workspace:WaitForChild("room2"):WaitForChild("Tools"):WaitForChild("BlueKey2")
tool.Equipped:Connect(function()
print("Equipped")
end)
tool.Activated:Connect(function()
print("Activated")
end)
while wait(2) do
print(tool.Parent) --to see if it registers when the player has it in their backpack or in their character
end
You’re getting the tool from Workspace, which isn’t good practice as the tool could be located anywhere. The player can’t activate the tool in Workspace. Where is your script located?
Connect the .Activated event after you put the tool in the player’s backpack/character. Also if your tool doesn’t have a handle make sure the .RequiresHandle property of the tool is disabled
it is a local script in the starterGUI this is an escape room game where the player finds the key and click on it so it is teleported to the players backpack.
If I am understanding you correctly, you want players to click the tool and it will appear in their backpack? If this is your intention, I would use ClickDetector.MouseClick
local LocalPlayer = game:GetService("Players").LocalPlayer
local Tool = workspace.room2.Tools.BlueKey2
Tool:GetPropertyChangedSignal("Parent"):Connect(function()
if Tool.Parent == LocalPlayer.Backpack then -- check if the tool gets put in the player's backpack
Tool.Activated:Connect(function() -- if the tool is put in backpack, then connect the .Activated signal
print("blue key activated")
end)
end
end)