How to physically show ammo/fuel?

I am making a game in which my character, a robot, must find fuel in order to stay alive. On the side of my actual fuel packs on the model, I want it to physically show how much fuel there is, kinda like spintires.

alt text

As you can see on the side of the car, there is a barrel with some green fuel in it, thats what im looking for.

PS It wouldnt let me find a topic besides this so thats why i have some weird topic :confused:

The image isn’t viewable, but as a general rule, you have two images, a full tank image and an empty tank image and you lay one on the other and display portions of the empty image (which conceals portions of the full) or not based on how much fuel you have.

Look up health bar tutorials for a common application with lots of tutorials on how to show a dynamic slider basically and really what you have is just a dynamic slider.

Unless you actually have a liquid in a barrel. If you do presumably you just add or remove liquid from a container.


Well it matters how you want to show it but this video shows a neat way to make health bar as an orb that can work on any shape. So why not check it out. If you need me to show you an example feel free to ask.

Video: Health Orb Video Link