Part
Part
local killPart = script.Parent
local canDamage = true
local killProperties = {
Color = Color3.fromRGB(0, 0, 255),
Material = Enum.Material.Neon,
Damage = 25,
CoolDown = 1
}
killPart.Color = killProperties["Color"]
killPart.Material = killProperties["Material"]
killPart.Touched:Connect(function(otherPart)
local humanoid = otherPart.Parent:FindFirstChild("Humanoid")
if humanoid and canDamage then
canDamage = false
humanoid:TakeDamage(killProperties["Damage"])
wait(killProperties["CoolDown"])
canDamage = true
end
end)