while true do if Player.Data.Hunger.Value<=0 then if Player.Data.IsElderVamp.Value==true then REGEN_STEP=.75 REGEN_RATE=.005 else if Player.Data.IsVamp.Value==true then REGEN_STEP=.75 REGEN_RATE=.0075 else REGEN_RATE=.0025 end end else if Player.Data.IsVamp.Value==true then REGEN_STEP=.25 REGEN_RATE=.015 else if Player.Data.IsElderVamp.Value==true then REGEN_STEP=.25 REGEN_RATE=.03 else REGEN_RATE=.005 end end end while Humanoid.Health<Humanoid.MaxHealth do local a=task.wait(REGEN_STEP)local f=(a*REGEN_RATE)*Humanoid.MaxHealth Humanoid.Health=math.min(Humanoid.Health+f,Humanoid.MaxHealth)if Humanoid.Health>0 and Humanoid.Health<Humanoid.MaxHealth then Player.Data.Hunger.Value=math.max(Player.Data.Hunger.Value-f,0)end end Humanoid.HealthChanged:Wait()end


while true do
	if Player.Data.Hunger.Value <= 0 then
		--// if the player has no hunger
		if Player.Data.IsElderVamp.Value == true then 
			REGEN_STEP = 0.75			
			REGEN_RATE = 0.5/100 
		else
		if Player.Data.IsVamp.Value == true then 
			REGEN_STEP = 0.75			
			REGEN_RATE = 0.75/100 
		else
			
			REGEN_RATE = 0.25/100
			end
		end
	else 
		
		if Player.Data.IsVamp.Value == true then 
			REGEN_STEP = 0.25
			REGEN_RATE = 1.5/100 
		else
			if Player.Data.IsElderVamp.Value == true then 
				REGEN_STEP = 0.25
				REGEN_RATE = 3/100 
		else
			REGEN_RATE = 0.5/100 
		end
	end
end
	while Humanoid.Health < Humanoid.MaxHealth do
		local dt = task.wait(REGEN_STEP)
		local dh = dt*REGEN_RATE*Humanoid.MaxHealth
		Humanoid.Health = math.min(Humanoid.Health+dh,Humanoid.MaxHealth)
		if Humanoid.Health > 0 and Humanoid.Health < Humanoid.MaxHealth then
			Player.Data.Hunger.Value = math.max(Player.Data.Hunger.Value-dh,0)
		end
	end
	Humanoid.HealthChanged:Wait()
end
