Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local Players = game:GetService("Players")
- local healingCircle = script.Parent
- local coolDown = .1
- local healthPercentage = .3
- for _, plr in next, Players:GetPlayers() do
- if plr.Character ~= nil and plr.Character:FindFirstChild("Tag") ~= nil then
- local center = ...
- local radius = 8
- local Character = plr.Character
- local Humanoid = Character:FindFirstChild("Humanoid")
- local HRP = Character:FindFirstChild("HumanoidRootPart")
- while wait(coolDown) do
- center = healingCircle.Position
- if (center - Vector3.new(HRP.Position.X, 0, HRP.Position.Z)).magnitude <= radius then
- if Humanoid then
- Humanoid.Health = Humanoid.Health + Humanoid.MaxHealth * healthPercentage/100
- end
- end
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement