Thread: Setting Lives
View Single Post
My idea for a health bar
Posts: n/a
Smile My idea for a health bar - 11-09-2014, 09:19 AM

I am currently making a game in alice 3 that has a health bar. The way it works is there are 10 billboards that I created with a custom image. To do that click on the project tab, then resource manager and then import image. If you create the billboard with the image on it it will be automatically resized to the image. Each of my billboards is a version of the health bar with a different amount of health. The way the bar works is I have a shape called healthBarMarker which is a vehicle to the camera and a variable called health. The health bar being currently used is also a vehicle of the camera. When the health variable decreases, the current health bar is given an opacity of 0 and the new health bar an opacity of 9. Then the first health bar ceases to be a vehicle of the camera and the new one does. The new one is then moved and oriented to the shape called healthBarMarker. Each of these actions has a duration of .01 seconds.
Reply With Quote