Monday, 27 February 2017

Idea Generation for Computer Games - Health and Energy setup.

The next pieces of the puzzle which needed to be made functional were the health and energy bars, represented in a HUD Widget using progress bars.

This was set up in exactly the same way as the widget which was applied to the NPC character implemented earlier in the overall procedure, only with more elements.
I added two progress bars and created progress bindings to allow the progress to be reflected based on a series of blueprints.
Once the levels of health and energy had been determined, I implemented the script within the character blueprint to allow these to interact with the respective 'min dmg' and 'max dmg' values which had been previously implemented into my system within a damage application string.

Once functional, I turned my attention to the energy depletion, and set the attacks to deplete my characters energy as previously seen, this further development however added some restrictions and varied amounts of energy required for specific moves.
Within each of my special attacks I simply set two extra nodes, one of which was a "Set energy' node attached to a minus float, and the other was a branch instructing the engine that if my characters energy was under a specific amount, any special moves could not be triggered. These branches made use of '>=' floats as I have used before in things like my distance check.

Below is a shot of a section of my blueprinting, showing that the special attack string can only fire if the energy levels meet the requirements, also shown is the dependency on certain moves within a primary combo to be active for the special attack to trigger;


No comments:

Post a Comment