I have a knife script that works. There's a small problem. When I equip it, the .touched event complete ignore .activated event. This is probably a simple fix, but I don't know how.
EDIT:
I FOUND A SOLUTION. sorry for wasting your time
CODE:
local tf = false
script.Parent.Parent.Equipped:Connect(function()
script.Parent.Parent.Activated:Connect(function()
if tf == false then
tf = true
local anim = script.Parent.Parent.Parent.Humanoid:LoadAnimation(script.Animation)
anim:Play()
script.Parent.Touched:Connect(function(part)
part.Parent:BreakJoints()
end)
wait(1.5)
tf = false
end
end)
end)

2 comments
make sure you accept your answer or mark the question as solved
You cannot accept your own answer yet alone vote on your answers/questions.