Tremulous Forum
		Mods => Modding Center => Topic started by: OhaiReapd on October 13, 2010, 09:50:21 pm
		
			
			- 
				I'm making a hud, and I would like to put a percentage of how much energy is left. This is for GPP and could you give me the code for it? :D
 
 Thanks
 
 ~Reapd
- 
				Check the GPP HUD and look at the charge bars.
			
- 
				Check the GPP HUD and look at the charge bars.
 
 
 The standard one? Hmmm.
- 
				Check the GPP HUD and look at the charge bars.
 
 
 The standard one? Hmmm.
 
 Any of 'em.
 
 It'll either go by % of charge or increase with the time the button is held. You could inverse that, to have a bar decrease with the time held.
- 
				Actually Plague Bringer, the standard charge bar (for Lucifer cannon, pounce etc.) uses its own special functions to determine its progress, among other things. Its not really a HUD thing.
			
- 
				Actually Plague Bringer, the standard charge bar (for Lucifer cannon, pounce etc.) uses its own special functions to determine its progress, among other things. Its not really a HUD thing.
 
 
 
 So it has to be coded in.
- 
				Actually Plague Bringer, the standard charge bar (for Lucifer cannon, pounce etc.) uses its own special functions to determine its progress, among other things. Its not really a HUD thing.
 
 In that case I'd assume that there's either no way to integrate a % bar directly into the HUD or it's too difficult or time consuming to do.
 
 
 EDIT:
 Do sections of the HUD have variable alphas? Can you arrange a few boxes and have them fade out one-by-one as stamina goes down?
- 
				If you can do it with ammo clips, why not with stamina?
			
- 
				If you can do it with ammo clips, why not with stamina?
 
 
 At a random guess, not knowing anything here, I would say the ammo clips are just bars made up of a number of rectangles and are decreased by the ammo usage and not percent.
- 
				I have a way to make a bar. But it's not what I want.
			
- 
				If you can do it with ammo clips, why not with stamina?
 
 
 At a random guess, not knowing anything here, I would say the ammo clips are just bars made up of a number of rectangles and are decreased by the ammo usage and not percent.
 
 Stamina is a value. We can read that value and increase or decrease bars accordingly.
- 
				If you can do it with ammo clips, why not with stamina?
 
 
 At a random guess, not knowing anything here, I would say the ammo clips are just bars made up of a number of rectangles and are decreased by the ammo usage and not percent.
 
 Stamina is a value. We can read that value and increase or decrease bars accordingly.
 
 
 Sooo mind telling me how?
- 
				If you can do it with ammo clips, why not with stamina?
 
 
 At a random guess, not knowing anything here, I would say the ammo clips are just bars made up of a number of rectangles and are decreased by the ammo usage and not percent.
 
 Stamina is a value. We can read that value and increase or decrease bars accordingly.
 
 
 Sooo mind telling me how?
 
 Check the code. It's in there somewhere.
- 
				If you can do it with ammo clips, why not with stamina?
 
 
 At a random guess, not knowing anything here, I would say the ammo clips are just bars made up of a number of rectangles and are decreased by the ammo usage and not percent.
 
 Stamina is a value. We can read that value and increase or decrease bars accordingly.
 
 
 Sooo mind telling me how?
 
 Check the code. It's in there somewhere.
 
 (http://humour-fun.net/photos/943.jpg)