Hi, I was trying to make the health bar but somehow it seems that it is not working. Here is the code. I made a GUI and inside the GUI i inserted ImageLabel . Thank you for reading/helping.
1 | H = script.Parent |
2 | P = script.Parent.Parent.Parent.Character.Humanoid |
3 |
4 | while true do |
5 | wait() |
6 | if P.Health < = 100 then |
7 | --Code removed due to problem has been fixed. |
8 | end |
Pss. Others are like if P.Health <=95,90,85, Etc... Psss. The script does not make the image invisible nor visible. It just show the last animation.
Script looks fine. I think there is a problem in Roblox Studio. Try different scripts on other games you made like simple FPS script, If it does not work that means There is a problem in Studio. Contact info@roblox.com. They might help you. :) Hope this helps your problem :)
Did you put in the correct id? For example, you forgot to subtract the id by 1.