so, let me explain some things first. i have a script that is inside a tool, and that tool is in StarterPack. when I play the game, the tool gets moved to the same group that .Humanoid is in. (my character in Workspace)
the problem here is that is that i don't know what the path to .Humanoid is. if p.Parent doesn't work, then what am i supposed to type in?
here's the error:
21:29:25.502 - humanoid is not a valid member of Folder 21:29:25.504 - Stack Begin 21:29:25.504 - Script Players.peasantvonpeasant.Backpack.WoodenSword.DamageForSwords’, Line 7
(humanoid is not a typo, it's a variable)
and here's the script:
local CanAttack = true script.Parent.Blade.Touched:Connect(function§ if CanAttack == true then CanAttack = false local humanoid = p.Parent:FindFirstChild(“Humanoid”) p.Parent.humanoid:TakeDamage(9) wait(.53) CanAttack = true end end)
i can give more details too, if you need it. sorry for any grammar mistakes as well, english ain't my first language.
please, if you know how to solve this answer! i've skewered the internet all day and couldn't find anything.

2 comments
Please do not repost your questions. Be patient.
make it more detailed pls