Important Announcement
Forum has been made read-only. Please click here for more information or here to return to The Spriters Resource.

I need Game Maker help thread
#1
Need help on Game Maker? Ask here folks!

How do I make a "drainable" hp bar that drains as hp goes down say for PACMAN please? Thank you.
#2
Isn't this what the Game Maker Community is for... ?
#3
True but no luck their yet. However I got an idea for my hp bar thing though.
#4
Oh, I'm sorry. That's probably where you'll get all your answers though.
#5
Quote:Isn't this what the Game Maker Community is for... ?
If they're anything like they were back when I went there, they'd all say RTFM and laugh at him.

Aaaaanyways~

You need to make an HP variable, and a max HP variable...

then;

draw_set_color(cl_black)
draw_rectangle(x,y,x+102,y+18,false)
draw_set_color(cl_green)
draw_rectangle(x+1,y+1,x+(max_hp/hp)*100,y+16,false)

in draw event. If you need a more elaborate demonstration, I'll write an example after work. Hope it helps Cute


Forum Jump:


Users browsing this thread: 1 Guest(s)