playMaker

Author Topic: Health Bar  (Read 4754 times)

davidflynn2

  • Playmaker Newbie
  • *
  • Posts: 5
Health Bar
« on: August 08, 2012, 02:19:48 PM »
Im trying to find a good tutorial on how to make a health system using health bars not numbers.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Health Bar
« Reply #1 on: August 09, 2012, 05:06:34 AM »
hi,

 Do you have an animated health bar with sprites? or do you expect a real "progress bar" meaning one graphic that will "stretch"

bye,

 Jean

davidflynn2

  • Playmaker Newbie
  • *
  • Posts: 5
Re: Health Bar
« Reply #2 on: August 09, 2012, 09:41:34 AM »
I was thinking one the updates by stretching im making a MMO stile game and im wanting to set up player health bars, and maby a mana below it but i know i can copy what I did with the other on and change some of the valuse to make the other one.  Im new to playmaker i have a bit of expericen with normal scripting but still learning.  I think playmaker may make it easyer for me to learn it.

4s4

  • Playmaker Newbie
  • *
  • Posts: 34
Re: Health Bar
« Reply #3 on: August 10, 2012, 06:04:48 AM »
Easiest way to do this would probably be to use the Set scale action.

Create a box(or any object you want to use as your health "bar") and add Set Scale to it
check the every frame box to make it update all the time
add proper float variables to preferred scale axis. for example float var "health"

Then create a FMS that monitors player: everytime player is hit, subract x amount from from "health" var.   

tbelgrave

  • Playmaker Newbie
  • *
  • Posts: 42
    • Ispyr Inc
Re: Health Bar
« Reply #4 on: September 30, 2012, 07:16:03 AM »
Hiya David, I'm new to all of this but see if what I did here will help http://hutonggames.com/playmakerforum/index.php?topic=1362.15 Although I'll try 4s4 suggestion as well.

~t
« Last Edit: September 30, 2012, 07:18:01 AM by lildragn »