Portfolio Project #3
For my final portfolio project, I aimed for a project that shows my general understanding of Unreal that I have developed over this semester and combine it into one project using C++ as much as possible.
Focus on C++ to create the groundwork for the general mechanics and use blueprints for other systems (Ui, AI, etc)
Use the skills and techniques I've developed in a non-blueprint environment
While nothing crazy complex with the weapons I aimed two have two distinctly different weapons that had lots of room for improvement and expansion. I used inheritance to make these weapons have the same basic mechanics but lots of room for individual parts. One weapon is a single-fire projectile weapon while the other automatic hitscan weapon.
Constructor for the BaseWeapon class which holds the basic values for any weapon we create and give to the player.
Constructor for the rifle child class. basic for the scope of this project but can be vastly expanded.
For firing the weapon, I had two different fire modes so I need to check which weapon was being used in order to fire the correct way. This was obtained but giving the player a list of weapons.
I wanted to give the player an entertaining experience and allow for a high level of play within a small game space while keeping with the repeating theme of expandability.
Both abilities are utilizing Unreal world timers to calculate their cooldowns, Unlimted Ammo uses two. One timer is used for cooldowns while the other manages how long the ability stays active this doesn't occur in the Dash ability as I am instantaneously adding a physics impulse to the player. I connected these timers to the Ui system...
I access the ability's current state based on the timer and adjust the icon in real-time for the player to always know when their ability is ready or on recharge.
My goal was to have enemies that have two phases, an initial phase where the monster moves toward you and hits you then they transition into a self-destructing attack where they explode and deal damage when close, this transition is shown with the change from base mannequin to a yellow one.
The behavior tree operates based on these two phases, both checking if they are within range to activate their ability. The right tree is the initial state and once it completes an attack it is stunned as they transition. The left tree is close to the first except when it is within range it deals damage and then is destroyed.
Overall this project was extremely challenging but I learned so much and am excited to potential do something simular in the future.