I wanted to make it so that when the player takes damage a blur appears, but right now it gives blur anytime the health changes instead of once when they take damage, so as they heal it keeps blurring, and also it does not play each time you get hit and you can see clearly multiple times without blur appearing
local player = game.Players.LocalPlayer
local tweenService = game:GetService("TweenService")
local lighting = game:GetService("Lighting")
local blurTween = tweenService:Create(lighting:WaitForChild("Blur"), TweenInfo.new(1, Enum.EasingStyle.Sine), {Size = 0})
local character = player.Character
local humanoid = character:WaitForChild("Humanoid")
--local health = humanoid.Health
local blur = game.Lighting.Blur
humanoid.HealthChanged:Connect(function()
if character.Humanoid.Health < 100 then
blur.Size = 15
blurTween:Play()
end
end)