This is what I've tried so far, however it gives me this error when I run it:
15:16:27.182 - Players.Player1.PlayerGui.ScreenGui.Frame.LocalScript:29: attempt to index field 'Image' (a string value) 15:16:27.183 - Stack Begin 15:16:27.184 - Script 'Players.Player1.PlayerGui.ScreenGui.Frame.LocalScript', Line 29 15:16:27.185 - Stack End
wait()
print("health")
local player = game.Players.LocalPlayer
local character = player.Character
local humanoid = character.Humanoid
local health = script.Parent.Health
local overlay = script.Parent.Overlay
local healthCounter = script.Parent.HealthText
game:GetService("RunService").Stepped:Connect(function()
local healthPoints = humanoid.Health/humanoid.MaxHealth
if healthPoints > 90 then
overlay.Image = "https://roblox.com/asset/id=714844375"
elseif healthPoints <= 90 then
overlay.Image.Image = "https://roblox.com/asset/id=716007653"
end
healthCounter.Text = math.floor(humanoid.Health)
end)
