Error while using the Activated event on a tool

I have an error whenever I click while using my tool:
Activated is not a valid member of Workspace “Workspace”

Here’s the code I have right now (not finished), it’s in a serverscript parented under the handle of the ball I’m making. I really have no idea why this error is happening. The code is running fine and it’s doing what it’s supposed to but it’s giving me this annoying error every time

local ball = script.Parent
local tool = ball.Parent

tool.Activated:Connect(function()
	local ballC = ball:Clone()
	ballC.Parent = workspace
	game.Debris:AddItem(ballC,10)
end)

if you need any more info, feel free to ask

local tool = ball.Parent is most likely not the tool and is referring to the Workspace, which is why you get the error saying “Activated is not a valid member of Workspace “Workspace””

i figured it out, i was just being stupid and forgot to delete the script in the cloned ball

noice, give ur self the check aggagaga

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