Health bar!?

Game Editor comments and discussion.

Health bar!?

Postby LUFFY » Tue May 23, 2006 9:57 pm

Does anyone know how to get 100/100 to be subtracted by 10 everytime you get hit?
LUFFY
 
Posts: 10
Joined: Wed Apr 05, 2006 12:04 am
Score: 0 Give a positive score

Postby Joshua Worth » Tue May 23, 2006 10:29 pm

Make a variable with the value 100. Then make a Collision sensor through the add menu on the actor, change some settings, Make a script editor from the drop down menu and type in "(VARIABLE_NAME)-=10;" dont forget the semi-colon at the end. Click ok and then click Immediate action.

I dont have time for a very detailed description, sorry. I hope this helped a little!
Stay sweet
User avatar
Joshua Worth
 
Posts: 515
Joined: Tue Jul 19, 2005 12:00 am
Location: Stralia
Score: 5 Give a positive score

Postby LUFFY » Tue May 23, 2006 11:27 pm

How do you make a varible of 100? :lol:
LUFFY
 
Posts: 10
Joined: Wed Apr 05, 2006 12:04 am
Score: 0 Give a positive score

Postby Joshua Worth » Wed May 24, 2006 3:20 am

Select the action, for example, create actor(when the game starts, or anothe actor creates that actor). Press add and then "create actor" then select "script editor" then type in "(VARIABLE_NAME)=100;", then, when the actor gets created, the variable will equal 100.

Just in case you didn't know: There are animated tutorials you can follow in the Help menu.
Stay sweet
User avatar
Joshua Worth
 
Posts: 515
Joined: Tue Jul 19, 2005 12:00 am
Location: Stralia
Score: 5 Give a positive score

Postby LUFFY » Wed May 24, 2006 11:53 pm

Huh???????? {i am a newbie at this} :oops: :lol:
LUFFY
 
Posts: 10
Joined: Wed Apr 05, 2006 12:04 am
Score: 0 Give a positive score

Postby Joshua Worth » Thu May 25, 2006 9:22 am

Did you have a look at the tutorials and help file?
Stay sweet
User avatar
Joshua Worth
 
Posts: 515
Joined: Tue Jul 19, 2005 12:00 am
Location: Stralia
Score: 5 Give a positive score


Return to GE - General

Who is online

Users browsing this forum: No registered users and 1 guest