Although this looks long and complicated, its not. It's incredibly repetitive.
I'm trying to make a new health Gui for my new game, which doesn't seem to be working.
There's no outputs what so ever, the script is a local script, inside StarterGui same as the GUI. All of the health image things that will be shown in the script are image labels. As the script is so repetitive, I'll only post the relevant bits (And don't worry about the spanish numbers, haha)
I think the problem may be not locating the players Humanoid properly. If so, How would I locate it correctly, haha
local gui = game.StarterGui.HealthGui
local health = script.Parent.Parent.Character.Humanoid.Health
----------------------------------------------------
local uno = gui.HealthStorer.First --1
local dos = gui.HealthStorer.Second --2
local tres = gui.HealthStorer.Third --3
local cuatro = gui.HealthStorer.Fourth--4
local cinco = gui.HealthStorer.Fith --5
local seis = gui.HealthStorer.Sixth --6
local siete = gui.HealthStorer.Seventh--7
local ocho = gui.HealthStorer.Eight --8
local nueve = gui.HealthStorer.Nine --9
local diez = gui.HealthStorer.Last --10
-----------------------------------------------------
local Red10 = gui.HealthStorer.DeathLast
local Red9 = gui.HealthStorer.DeathNine
local Red8 = gui.HealthStorer.DeathEight
local Red7 = gui.HealthStorer.DeathSeven
local Red6 = gui.HealthStorer.DeathSix
while true do wait()
if health < 100 and health >= 90 then
uno.Visible = false and dos,tres,cuatro,cinco,seis,siete,ocho,nueve,diez.Visible == false wait (.25)
dos,tres,cuatro,cinco,seis,siete,ocho,nueve,diez.Visible = true
if health <= 89 and health >= 80 then
dos.Visible = false and tres,cuatro,cinco,seis,siete,ocho,nueve,diez.Visible == false wait (.25)
tres,cuatro,cinco,seis,siete,ocho,nueve,diez.Visible = true
if health <= 79 and health >= 70 then
tres.Visible = false and cuatro,cinco,seis,siete,ocho,nueve,diez.Visible == false wait (.25)
cuatro,cinco,seis,siete,ocho,nueve,diez.Visible = true
if health <= 69 and health >= 60 then
cuatro.Visible = false and cinco,seis,siete,ocho,nueve,diez.Visible == false wait (.25)
cinco,seis,siete,ocho,nueve,diez.Visible = true
if health <= 59 and health >= 50 then
cinco.Visible = false and seis,siete,ocho,nueve,diez.Visible == false wait (.25)
seis,siete,ocho,nueve,diez.Visible = true
And so on... Till it gets to
if health == 1 then _____
The problem is, none of the image labels that are representing the health, are disappearing when health is within the range of the statement. Any help on this would be great. Thanks c:

3 comments
I updated my answer. If it doesn't work, send me another PM. I'll be AFK for an hour.
Oh, nice to see I am not the only one who will name variables or functions in spanish numbers. I have a hard time thinking of good names for some functions and variables xD.
Haha, I was going to do them 1,2,3 exc, but figured that may cause some problems and the only other thing I could think of was the Spanish numbers xD