Specific attack type does not do damage until another type of attack is used
So I've been going through the Skill System tutorial series by UnrealGaimeDev on YouTube. I've been following along and picking up a few new tricks along the way but now I've hit a speed bump that has me at a complete loss because I can't find ANY reason that this should be happening.
So to give a bit of extra information. The skills / abilities / spells are based off a Master parent skill and are children of it. One group of spells is setup to function as AoEs using the player as the epicenter and works perfectly. The second set are homing attacks (Magic Missile). While the AoE can be fired off at any time so long as the player has the correct amount of mana to spend; but the projectile spells require a selected target.
So the AoE spells work perfectly in terms of animation, execution and damage dealt to enemies within range. The enemy selection is also working perfectly. The projectile spells will not be cast without a selected enemy and when one is selected and the spell is cast, the homing function works as intended; however, the projectile spell will not do any damage to the enemy is hits.
Now the really strange part is that I can cast the projectile spell a hundred times and it will not do any damage at all to the enemy even though all of the blueprint code is being executed and the correct damage values are being used (already tested and verified), UNTIL I hit the enemy with an AoE attack. Once I connect with an AoE, which does it's damage properly, all following projectile spells will cause damage from that point onward, and not just against the enemy that was hit with the AoE attack; but all other enemies.
My first thought was that the variable that handles the enemy reference in order to do damage to it wasn't being set properly by the projectile spells but that's not the case.
I've pretty much run out of ideas and am rapidly approaching the point of bashing my head off the desk repeatedly. If anyone can shed any light on this I'd be eternally grateful!
The video that covers the creation of the Projectile Skill is: https://www.youtube.com/watch?v=axRSYhnC0SU&list=PLmKKTERcjTPLIW5fPHRaFcl1hfRb0okbz∈dex=18.
asked Jun 01 '19 at 05:02 AM in Blueprint Scripting
Oh dear God do I feel stupid now. In the damage calculation function, when it checks the effectiveness of the skill based on the element type of the attack and the defender, I was missing an execution connection.
PUBLIC SERVICE ANNOUNCEMENT: If you're tired, or having a foggy brain / brain fart day, do NOT attempt to follow logic. You'll only live to regret it.
answered Jun 02 '19 at 12:15 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here