I made a sword with client cast but when hitting the player it detects each limb it touches and that makes it do more damage
I want hitting a player to do the damage it’s supposed to do.
I try to make it stop damaging when the sword hits someone but that means that if the sword touches 2 players it will only damage one
Does anyone know a way to hit many people at once but do the same damage per player?
local charDebounces = {}
Sword.Hit:Connect(function(part)
local Hum = part.Parent:FindFirstChild("Humanoid")
if not Hum then return end
if charDebounces[Hum] then return end
charDebounces[Hum] = true
-- Damage
end)
AnimationEnd:Connect(function()
table.clear(charDebounces)
end)