local P=true local z=nil script.Parent.Treat.Frame.BandFrame.Bandage.MouseButton1Down:Connect(function()if P and(Bandage.Value>0 and(Human.Health>0 and not Char.ACS_Client:GetAttribute("\067\111\108\108\097\112\115\101\100")))then P=false if Target.Value==nil then if Char.ACS_Client:GetAttribute("\066\108\101\101\100\105\110\103")then Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(5,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(5)Functions.MedHandler:FireServer(nil,1)end else if Target.Value.Character.ACS_Client:GetAttribute("\066\108\101\101\100\105\110\103")then z=Target.Value Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(5,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(5)Functions.MedHandler:FireServer(z,1)end end P=true end end)script.Parent.Treat.Frame.BandFrame.Splint.MouseButton1Down:Connect(function()if P and(Splint.Value>0 and(Human.Health>0 and not Char.ACS_Client:GetAttribute("\067\111\108\108\097\112\115\101\100")))then P=false if Target.Value==nil then if Char.ACS_Client:GetAttribute("\073\110\106\117\114\101\100")then Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(5,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(5)Functions.MedHandler:FireServer(nil,2)end else if Target.Value.Character.ACS_Client:GetAttribute("\073\110\106\117\114\101\100")then z=Target.Value Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(5,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(5)Functions.MedHandler:FireServer(z,2)end end P=true end end)script.Parent.Treat.Frame.BandFrame.Tourniquet.MouseButton1Down:Connect(function()if P and(Human.Health>0 and not Char.ACS_Client:GetAttribute("\067\111\108\108\097\112\115\101\100"))then P=false if Target.Value==nil then if Char.ACS_Client:GetAttribute("\066\108\101\101\100\105\110\103")==true or Char.ACS_Client:GetAttribute("\084\111\117\114\110\105\113\117\101\116")then Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(1.5,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(1.5)Functions.MedHandler:FireServer(nil,3)end else if Target.Value.Character.ACS_Client:GetAttribute("\066\108\101\101\100\105\110\103")or Target.Value.Character.ACS_Client:GetAttribute("\084\111\117\114\110\105\113\117\101\116")then z=Target.Value Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(1.5,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(1.5)Functions.MedHandler:FireServer(z,3)end end P=true end end)script.Parent.Treat.Frame.MedFrame.PainKiller.MouseButton1Down:Connect(function()if P and(PainKiller.Value>0 and(Human.Health>0 and not Char.ACS_Client:GetAttribute("\067\111\108\108\097\112\115\101\100")))then P=false if Target.Value==nil then if Char.ACS_Client.Variaveis.Dor.Value>0 then Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(1.5,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(1.5)Functions.MedHandler:FireServer(nil,4)end else if Target.Value.Character.ACS_Client.Variaveis.Dor.Value>0 then z=Target.Value Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(1.5,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(1.5)Functions.MedHandler:FireServer(z,4)end end P=true end end)script.Parent.Treat.Frame.MedFrame.Energy.MouseButton1Down:Connect(function()if P and(EnergyShot.Value>0 and(Human.Health>0 and not Char.ACS_Client:GetAttribute("\067\111\108\108\097\112\115\101\100")))then P=false if Target.Value==nil then if Char.Humanoid.Health<Char.Humanoid.MaxHealth then Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(3,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(3)Functions.MedHandler:FireServer(nil,5)end else if Target.Value.Character.Humanoid.Health<Target.Value.Character.Humanoid.MaxHealth then z=Target.Value Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(3,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(3)Functions.MedHandler:FireServer(z,5)end end P=true end end)script.Parent.Treat.Frame.NeedFrame.Morphine.MouseButton1Down:Connect(function()if P and(Morphine.Value>0 and(Human.Health>0 and not Char.ACS_Client:GetAttribute("\067\111\108\108\097\112\115\101\100")))then P=false if Target.Value==nil then if Char.ACS_Client.Variaveis.Dor.Value>0 then Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(10,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(10)Functions.MedHandler:FireServer(nil,6)end else if Target.Value.Character.ACS_Client.Variaveis.Dor.Value>0 then z=Target.Value Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(10,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(10)Functions.MedHandler:FireServer(z,6)end end P=true end end)script.Parent.Treat.Frame.NeedFrame.Epineprhine.MouseButton1Down:Connect(function()if P and(Morphine.Value>0 and(Human.Health>0 and not Char.ACS_Client:GetAttribute("\067\111\108\108\097\112\115\101\100")))then P=false if Target.Value==nil then if Char.Humanoid.Health<Char.Humanoid.MaxHealth then Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(10,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(10)Functions.MedHandler:FireServer(nil,7)end else if Target.Value.Character.ACS_Client:GetAttribute("\067\111\108\108\097\112\115\101\100")then z=Target.Value Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(10,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(10)Functions.MedHandler:FireServer(z,7)end end P=true end end)script.Parent.Treat.Frame.OtherFrame.Bloodbag.MouseButton1Down:Connect(function()if P and(SacoDeSangue.Value>0 and(Human.Health>0 and not Char.ACS_Client:GetAttribute("\067\111\108\108\097\112\115\101\100")))then P=false if Target.Value==nil then if Char.ACS_Client.Variaveis.Sangue.Value<Char.ACS_Client.Variaveis.Sangue.MaxValue then Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(20,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(20)Functions.MedHandler:FireServer(nil,8)end else if Target.Value.Character.ACS_Client.Variaveis.Sangue.Value<Target.Value.Character.ACS_Client.Variaveis.Sangue.MaxValue then z=Target.Value Timer.Size=UDim2.new(0,0,1,0);(TS:Create(Timer,TweenInfo.new(20,Enum.EasingStyle.Linear),{Size=UDim2.new(1,0,1,0)})):Play()wait(20)Functions.MedHandler:FireServer(z,8)end end P=true end end)

local TreatDebounce = true
local SavedTarget 	= nil

script.Parent.Treat.Frame.BandFrame.Bandage.MouseButton1Down:Connect(function()
	if TreatDebounce and Bandage.Value > 0 and Human.Health > 0 and not Char.ACS_Client:GetAttribute("Collapsed") then
		TreatDebounce = false
		if Target.Value == nil then
			if Char.ACS_Client:GetAttribute("Bleeding") then
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(5,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(5)
				Functions.MedHandler:FireServer(nil,1)
			end
		else
			if Target.Value.Character.ACS_Client:GetAttribute("Bleeding") then
				SavedTarget = Target.Value
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(5,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(5)
				Functions.MedHandler:FireServer(SavedTarget,1)
			end
		end
		TreatDebounce = true
	end
end)

script.Parent.Treat.Frame.BandFrame.Splint.MouseButton1Down:Connect(function()
	if TreatDebounce and Splint.Value > 0 and Human.Health > 0 and not Char.ACS_Client:GetAttribute("Collapsed") then
		TreatDebounce = false
		if Target.Value == nil then
			if Char.ACS_Client:GetAttribute("Injured") then
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(5,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(5)
				Functions.MedHandler:FireServer(nil,2)
			end
		else
			if Target.Value.Character.ACS_Client:GetAttribute("Injured") then
				SavedTarget = Target.Value
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(5,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(5)
				Functions.MedHandler:FireServer(SavedTarget,2)
			end
		end
		TreatDebounce = true
	end
end)

script.Parent.Treat.Frame.BandFrame.Tourniquet.MouseButton1Down:Connect(function()
	if TreatDebounce and Human.Health > 0 and not Char.ACS_Client:GetAttribute("Collapsed") then
		TreatDebounce = false
		if Target.Value == nil then
			if Char.ACS_Client:GetAttribute("Bleeding") == true or Char.ACS_Client:GetAttribute("Tourniquet")then
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(1.5,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(1.5)
				Functions.MedHandler:FireServer(nil,3)
			end
		else
			if Target.Value.Character.ACS_Client:GetAttribute("Bleeding") or Target.Value.Character.ACS_Client:GetAttribute("Tourniquet") then
				SavedTarget = Target.Value
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(1.5,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(1.5)
				Functions.MedHandler:FireServer(SavedTarget,3)
			end
		end
		TreatDebounce = true
	end
end)

script.Parent.Treat.Frame.MedFrame.PainKiller.MouseButton1Down:Connect(function()
	if TreatDebounce and PainKiller.Value > 0 and Human.Health > 0 and not Char.ACS_Client:GetAttribute("Collapsed") then
		TreatDebounce = false
		if Target.Value == nil then
			if Char.ACS_Client.Variaveis.Dor.Value > 0 then
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(1.5,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(1.5)
				Functions.MedHandler:FireServer(nil,4)
			end
		else
			if Target.Value.Character.ACS_Client.Variaveis.Dor.Value > 0 then
				SavedTarget = Target.Value
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(1.5,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(1.5)
				Functions.MedHandler:FireServer(SavedTarget,4)
			end
		end
		TreatDebounce = true
	end
end)

script.Parent.Treat.Frame.MedFrame.Energy.MouseButton1Down:Connect(function()
	if TreatDebounce and EnergyShot.Value > 0 and Human.Health > 0 and not Char.ACS_Client:GetAttribute("Collapsed") then
		TreatDebounce = false
		if Target.Value == nil then
			if Char.Humanoid.Health < Char.Humanoid.MaxHealth then
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(3,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(3)
				Functions.MedHandler:FireServer(nil,5)
			end
		else
			if Target.Value.Character.Humanoid.Health < Target.Value.Character.Humanoid.MaxHealth then
				SavedTarget = Target.Value
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(3,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(3)
				Functions.MedHandler:FireServer(SavedTarget,5)
			end
		end
		TreatDebounce = true
	end
end)

script.Parent.Treat.Frame.NeedFrame.Morphine.MouseButton1Down:Connect(function()
	if TreatDebounce and Morphine.Value > 0 and Human.Health > 0 and not Char.ACS_Client:GetAttribute("Collapsed") then
		TreatDebounce = false
		if Target.Value == nil then
			if Char.ACS_Client.Variaveis.Dor.Value > 0 then
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(10,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(10)
				Functions.MedHandler:FireServer(nil,6)
			end
		else
			if Target.Value.Character.ACS_Client.Variaveis.Dor.Value > 0 then
				SavedTarget = Target.Value
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(10,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(10)
				Functions.MedHandler:FireServer(SavedTarget,6)
			end
		end
		TreatDebounce = true
	end
end)

script.Parent.Treat.Frame.NeedFrame.Epineprhine.MouseButton1Down:Connect(function()
	if TreatDebounce and Morphine.Value > 0 and Human.Health > 0 and not Char.ACS_Client:GetAttribute("Collapsed") then
		TreatDebounce = false
		if Target.Value == nil then
			if Char.Humanoid.Health < Char.Humanoid.MaxHealth then
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(10,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(10)
				Functions.MedHandler:FireServer(nil,7)
			end
		else
			if Target.Value.Character.ACS_Client:GetAttribute("Collapsed") then
				SavedTarget = Target.Value
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(10,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(10)
				Functions.MedHandler:FireServer(SavedTarget,7)
			end
		end
		TreatDebounce = true
	end
end)

script.Parent.Treat.Frame.OtherFrame.Bloodbag.MouseButton1Down:Connect(function()
	if TreatDebounce and SacoDeSangue.Value > 0 and Human.Health > 0 and not Char.ACS_Client:GetAttribute("Collapsed") then
		TreatDebounce = false
		if Target.Value == nil then	
			if Char.ACS_Client.Variaveis.Sangue.Value < Char.ACS_Client.Variaveis.Sangue.MaxValue then
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(20,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(20)
				Functions.MedHandler:FireServer(nil,8)
			end
		else
			if Target.Value.Character.ACS_Client.Variaveis.Sangue.Value < Target.Value.Character.ACS_Client.Variaveis.Sangue.MaxValue then
				SavedTarget = Target.Value
				Timer.Size = UDim2.new(0,0,1,0)
				TS:Create(Timer, TweenInfo.new(20,Enum.EasingStyle.Linear), {Size =  UDim2.new(1,0,1,0)}):Play()
				wait(20)
				Functions.MedHandler:FireServer(SavedTarget,8)
			end
		end
		TreatDebounce = true
	end
end)

