I would like to register damage from various types of weapons such as arrow projectiles and melee attacks. I am able to accomplish inflicting damage to a health bar, but would also like to have damage affect a defense/shield meter as well. For example, an arrow hit might do 20 dmg but will do 7 to health and 13 to the defense until the defense runs out and then only affects health.
I am just looking for the best way to set up damage for more than one type. I could set each attack to subtract a specified health and defense from the character on object collision, but was wondering if there was a better/more efficient way.
Should i use the EventHit event to apply damage, and somehow use a Break hit to incorporate the second type of damage that is inflicted at the same time? Woudl this be something I could set up in an enumeration or structure for weapon classes? I know you could do an enum for classes but where would I set the specs for each class like what kind of damage they do?
A point in the right direction would be greatly appreciated. Thanks