SKP_7.HealthChanged:Connect(function(c)if c<SKP_20 and c<SKP_7.MaxHealth/2 then local X=(c/SKP_20-1)*-1 local o=script.FX.Blur:clone()o.Parent=game.Workspace.CurrentCamera local K=script.FX.ColorCorrection:clone()K.Parent=game.Workspace.CurrentCamera o.Size=((c/SKP_7.MaxHealth)/2-1)*-35 K.TintColor=Color3.new(1,(c/2)/SKP_20,(c/2)/SKP_20);(SKP_10:Create(o,TweenInfo.new(3*X,Enum.EasingStyle.Sine,Enum.EasingDirection.Out,0,false,0),{Size=0})):Play();(SKP_10:Create(K,TweenInfo.new(3*X,Enum.EasingStyle.Sine,Enum.EasingDirection.In,0,false,0),{TintColor=Color3.new(1,1,1)})):Play()SKP_11:AddItem(o,3*X)SKP_11:AddItem(K,3*X)end SKP_20=c end)local c=false SKP_18.Changed:Connect(function(c) end)SKP_17.Changed:Connect(function(c)if c>=SKP_17.MaxValue/2 then SKP_12.Saturation=math.max(-1,(c-SKP_17.MaxValue/2)/(SKP_17.MaxValue/2)-1)end end)SKP_HC.Changed:Connect(function(c)if c>=3 then SKP_4.Render:FireServer(true,"\078\047\065")end end);(SKP_15:GetAttributeChangedSignal("\067\111\108\108\097\112\115\101\100")):Connect(function()local c=SKP_15:GetAttribute("\067\111\108\108\097\112\115\101\100")if c==true then SKP_13.Brightness=-10 else SKP_13.Brightness=0 end end)SKP_7.Died:Connect(function()Morto=true SKP_7.AutoRotate=false SKP_13.TintColor=Color3.new(1,1,1)SKP_12.Saturation=0 SKP_12.Contrast=0 SKP_14.Size=0 SKP_12.Saturation=0 SKP_12.Contrast=0 SKP_15.Variaveis.Dor.Value=0 for c,X in pairs(SKP_2.Character:GetChildren())do if X:IsA("\077\101\115\104\080\097\114\116")or X:IsA("\080\097\114\116")then X.LocalTransparencyModifier=0 end end if SKP_19==true then Tween=(SKP_10:Create(SKP_13,TweenInfo.new(game.Players.RespawnTime/1.25,Enum.EasingStyle.Linear,Enum.EasingDirection.InOut,0,false,0),{Brightness=0;Contrast=0;TintColor=Color3.new(0,0,0)})):Play()end end)local X=script.Parent.Parent.Humanoid local o=game.ReplicatedStorage.ACS_Engine.Events.MedSys.Collapse function onChanged()if SKP_17.Value<=3500 or SKP_18.Value>=200 or SKP_15:GetAttribute("\067\111\108\108\097\112\115\101\100")then SKP_6:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack,false)X:UnequipTools()o:FireServer()elseif SKP_17.Value>3500 and(SKP_18.Value<200 and not SKP_15:GetAttribute("\067\111\108\108\097\112\115\101\100"))then o:FireServer()if not SKP_15:GetAttribute("\083\117\114\114\101\110\100\101\114")then SKP_6:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack,true)end end end onChanged()SKP_17.Changed:Connect(onChanged)SKP_18.Changed:Connect(onChanged);(SKP_15:GetAttributeChangedSignal("\083\117\114\114\101\110\100\101\114")):Connect(function()local c=SKP_15:GetAttribute("\083\117\114\114\101\110\100\101\114")if c==true then X:UnequipTools()SKP_6:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack,false)else SKP_6:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack,true)end end)local K=game:GetService("\082\117\110\083\101\114\118\105\099\101")K.RenderStepped:connect(function(c)if Morto and(SKP_2.Character and SKP_2.Character:FindFirstChild("\072\101\097\100")~=nil)then game.Workspace.CurrentCamera.CameraType=Enum.CameraType.Scriptable game.Workspace.CurrentCamera.CFrame=SKP_2.Character.Head.CFrame end end)while true do(SKP_10:Create(SKP_14,TweenInfo.new(2.5,Enum.EasingStyle.Elastic,Enum.EasingDirection.Out,0,false,2.5),{Size=(SKP_15.Variaveis.Dor.Value/200)*25})):Play()wait(5);(SKP_10:Create(SKP_14,TweenInfo.new(1,Enum.EasingStyle.Sine,Enum.EasingDirection.In,0,false,0),{Size=0})):Play()wait(2.5)end
--SKP_7:SetStateEnabled(Enum.HumanoidStateType.Dead, false)

SKP_7.HealthChanged:Connect(function(Health)
	if Health < SKP_20 and Health < SKP_7.MaxHealth / 2 then
		local Hurt = ((Health / SKP_20) - 1) * -1

		local SKP_22 = script.FX.Blur:clone()
		SKP_22.Parent = game.Workspace.CurrentCamera

		local SKP_23 = script.FX.ColorCorrection:clone()
		SKP_23.Parent = game.Workspace.CurrentCamera

		SKP_22.Size = ((Health / SKP_7.MaxHealth / 2) - 1) * -35
		SKP_23.TintColor = Color3.new(1, ((Health / 2) / SKP_20), ((Health / 2) / SKP_20))

		SKP_10:Create(
			SKP_22,
			TweenInfo.new(3 * Hurt, Enum.EasingStyle.Sine, Enum.EasingDirection.Out, 0, false, 0),
			{ Size = 0 }
		):Play()
		SKP_10:Create(
			SKP_23,
			TweenInfo.new(3 * Hurt, Enum.EasingStyle.Sine, Enum.EasingDirection.In, 0, false, 0),
			{ TintColor = Color3.new(1, 1, 1) }
		):Play()

		SKP_11:AddItem(SKP_22, 3 * Hurt)
		SKP_11:AddItem(SKP_23, 3 * Hurt)
	end

	SKP_20 = Health
end)

local SKP_24 = false

SKP_18.Changed:Connect(function(Valor) end)

SKP_17.Changed:Connect(function(Valor)
	if Valor >= SKP_17.MaxValue / 2 then
		SKP_12.Saturation = math.max(-1, (Valor - (SKP_17.MaxValue / 2)) / (SKP_17.MaxValue / 2) - 1)
	end
end)

SKP_HC.Changed:Connect(function(Valor)
	if Valor >= 3 then
		SKP_4.Render:FireServer(true, "N/A")
	end
end)

SKP_15:GetAttributeChangedSignal("Collapsed"):Connect(function()
	local Valor = SKP_15:GetAttribute("Collapsed")
	if Valor == true then
		SKP_13.Brightness = -10
	else
		SKP_13.Brightness = 0
	end
end)

SKP_7.Died:Connect(function()
	Morto = true

	SKP_7.AutoRotate = false

	SKP_13.TintColor = Color3.new(1, 1, 1)

	--SKP_13.Brightness = 0

	SKP_12.Saturation = 0

	SKP_12.Contrast = 0

	SKP_14.Size = 0

	SKP_12.Saturation = 0

	SKP_12.Contrast = 0

	SKP_15.Variaveis.Dor.Value = 0

	for _, Child in pairs(SKP_2.Character:GetChildren()) do
		if Child:IsA("MeshPart") or Child:IsA("Part") then
			Child.LocalTransparencyModifier = 0
		end
	end

	if SKP_19 == true then
		Tween = SKP_10:Create(
			SKP_13,
			TweenInfo.new(
				game.Players.RespawnTime / 1.25,
				Enum.EasingStyle.Linear,
				Enum.EasingDirection.InOut,
				0,
				false,
				0
			),
			{ Brightness = 0, Contrast = 0, TintColor = Color3.new(0, 0, 0) }
		):Play()
	end
end)

local SKP_25 = script.Parent.Parent.Humanoid
local SKP_26 = game.ReplicatedStorage.ACS_Engine.Events.MedSys.Collapse

function onChanged()
	if (SKP_17.Value <= 3500) or (SKP_18.Value >= 200) or SKP_15:GetAttribute("Collapsed") then
		SKP_6:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack, false)
		SKP_25:UnequipTools()
		SKP_26:FireServer()
	elseif (SKP_17.Value > 3500) and (SKP_18.Value < 200) and not SKP_15:GetAttribute("Collapsed") then -- YAY A MEDIC ARRIVED! =D
		SKP_26:FireServer()
		if not SKP_15:GetAttribute("Surrender") then
			SKP_6:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack, true)
		end
	end
end

onChanged()

SKP_17.Changed:Connect(onChanged)
SKP_18.Changed:Connect(onChanged)

SKP_15:GetAttributeChangedSignal("Surrender"):Connect(function()
	local Valor = SKP_15:GetAttribute("Surrender")
	if Valor == true then
		SKP_25:UnequipTools()
		SKP_6:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack, false)
	else
		SKP_6:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack, true)
	end
end)

local RS = game:GetService("RunService")
RS.RenderStepped:connect(function(Update)
	if Morto and SKP_2.Character and SKP_2.Character:FindFirstChild("Head") ~= nil then
		game.Workspace.CurrentCamera.CameraType = Enum.CameraType.Scriptable
		game.Workspace.CurrentCamera.CFrame = SKP_2.Character.Head.CFrame
	end
end)

while true do
	SKP_10:Create(
		SKP_14,
		TweenInfo.new(2.5, Enum.EasingStyle.Elastic, Enum.EasingDirection.Out, 0, false, 2.5),
		{ Size = (SKP_15.Variaveis.Dor.Value / 200) * 25 }
	):Play()
	wait(5)
	SKP_10:Create(SKP_14, TweenInfo.new(1, Enum.EasingStyle.Sine, Enum.EasingDirection.In, 0, false, 0), { Size = 0 })
		:Play()
	wait(2.5)
end
