I'm Making a Game: Heads Up Display
by fobwashed
What's New? Update Edit What's new is the item Bar on the far upper right hand side. I'll go into detail about the changes in a reply below! Previous Updates Below Update: Added the ability to adjust the screen safe area. Nothing really all that interesting to see but it's important IMO. Very short vid -_-;; New Vid. This one is in HD. For full deets see post below =D At this point I can't real...
What's New? Update Edit
What's new is the item Bar on the far upper right hand side. I'll go into detail about the changes in a reply below!
Previous Updates Below
Update: Added the ability to adjust the screen safe area. Nothing really all that interesting to see but it's important IMO. Very short vid -_-;;
New Vid. This one is in HD. For full deets see post below =D
At this point I can't really associate anything in this latest update with the Loot post so I'll make a new general one that I'll put anything having to do with the Heads Up Display into.

It's actually harder to see the life bar at the lower recorded resolution. Also, as I mentioned in the description of this video, there are many things that I'll still need to adjust. Walll of Text describing changes to follow.
The most obvious thing is the Health Hud. It's still not done as I plan on adding some particle effects, a few other doodads, shake when hit and also pan on having it move out of the way when no action is taking place.
What's there though is a 4 segment health system. Once the player takes damage below a segment, it is permanently reduced but if the player takes damage but isn't below the next segment, he will heal back up to the full segment.
There is also reasoning behind the madness of the health segments being of varying size. The first segment is relatively small. I chose to have it smaller so that the player can experience permanent health loss early on in a fight. This will immediately give the player a sense of actual loss and danger in a fight rather than not worrying about their health due to its regenerating nature.
The following two segments are also smaller than the last. This is for pretty much the same reason in that I want the player in a fight to not depend too heavily on the regenerating nature of health and try to play wisely knowing the risk of permanent health loss.
The final segment is the largest and this is so that the player will always be able to regen to a fair amount of health where they won't feel like they are always a mistake or two away from death. It's also a buffer for myself to be able to design fights in the game without worrying that the player has reached a certain area with so little health that it's either impossible or incredibly difficult.
Another benefit of the staggered sizes of the health segments is that this will cause the player to really think over whether or not to use a health item to regenerate a lost segment. On one hand, it's always good to have more health but on the other hand, is it a waste to use a health item to regenerate the smaller size segments? For this to be a decision that takes place before an encounter rather than during one, I plan on having the health items take a bit of time to take effect. This way, it's less desirable to use it mid combat.
I've also added a few graphical things to keep the health more interesting. For one, when health is actually regenning, the gears move faster. As the player loses segments, individual gears stop working entirely. Later on, I plan on adding some sparks and steam and whatnot to enhance the effect but you can see what I mean.
Apart from the health stuff, I cleaned up a lot of the code. The largest part being that I moved all the combat checks into the individual enemies and objects so that they're called during their individual update methods rather than going through them one at a time in the class they're contained in.
I've also created a completely separate list that contains all the dead objects. What happens now is when an object dies, it is removed from the active objects list and inserted into the dead objects list. The dead objects list is not called on during any updates except to be drawn in the proper location at the right layerDepth. This allows me to save all the calls it would have made to the dead object to check whether or not it's dead when everything else is going through the collision, attacking, etc.
Pretty good for a few hours. Really though, the art is what took up like 80% of the time -_-;; I feel like I've got a pretty solid handle on coding at this point and it's just a matter of thinking things up and having the assets to put them in and make it work. The health bar is it's own class that is declared in the HUD class. From there it updates only what's needed in the Health bar including the position. This will make it incredibly easy to move the health bar in and out of the scene later when I get around to it.