local healingpad = script.Parent ---Healing Pad
local Green = Color3.fromRGB(96, 255, 99) ---Color Green
local Red = Color3.fromRGB(255,53,53) ---Color Red
local coolDown = 5 ---Cooldown Time
local debounce = false
function heal (hit)
if debounce then return end
if hit.Parent:FindFirstChild("Humanoid") then
print("health")
print(hit.Parent.Humanoid.Health)
hit.Parent.Humanoid.Health += 25
debounce = true
wait(coolDown)
debounce = false
end
end
healingpad.Touched:Connect(heal)
I made this healing script but it doesn't work. Idk why though.

8 comments
Maybe you're substracting the health on the client so the server doesn't see it being lower?
How do I subtract it on the server?
By changing it from a LocalScript to a Script.
it is a server script tho
it is inside of the healing pad part
For some reason setting it to equal works but not adding to it.
Nothing wrong with your script. But you're most likely setting the health to 1 on the client while testing it. Switch to server and set the health before you test the script.
Thanks can you put that as the answer so I can mark it as answered.