Tool.Activated() not working?

Hello, so i was trying to do a axe gear (to try and make a game similar to Lumber Tycoon 2) but the Tool.Activated is not firing.

  1. What did i try?
    So far i tried making my part of the script where it detectects if its equipped both server and client sided, i tried checking how they did this in free sword models and they did not work either. I even checked on the devforum and documentary to see if i was doing it wrong.

  2. My Issue? After clicking while i have the tool equipped, it does not detect that i activated it.

  3. What do i want to achieve? I want to see if its a bug, or i am doing it wrong

Some more details (the script i used to attempt debuging it, but it also is used on my gear.)

 local Tool1 = script.Parent

Tool1.Equipped:Connect(function()
	print("Equipped")
end)

Tool1.Activated:Connect(function()
	print("Activated")
end)

while wait(2) do
	print(Tool1.Parent)
end

Have you tried unchecking or checking the RequiresHandle option?

Yes, i’ve tried but it still did not work

What about ManualActivationOnly?

I also tried that and it doesn’t work

It does print “Equipped” right?

Yes, it prints “Equipped” but not “Activated” when used

The only thing left to check is the Property Called Enabled, there is nothing wrong with the script.

The property “Enabled” is currently set to true, on both the script and tool

Try putting the Activated function inside the tool.

local Tool1 = script.Parent

Tool1.Equipped:Connect(function()
	print("Equipped")

	Tool1.Activated:Connect(function()
		print("Activated")
	end)
end)

while wait(2) do
	print(Tool1.Parent)
end

Did you commit the script if you are working on team create? Or else the script won’t save and publish.

It still, doesn’t work somehow
Its not printing the “Activated” part

I have team create off, im not sure why its not working.

Well, since you can detect the equipping event, you could use a variable and set it to true when the tool is equipped and set it to false when unequipped and detect if the player clicked mousebutton1 using UserInputService (or ContextActionService) then check if the equipped variable is true then manually activate the tool Tool:Activate(), i think you also need ManualActivationOnly to be set to true.

This seems to work perfectly, thanks!

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.