Hi,
So, I have searched through the forums before asking this, they may have been asked before but I couldn't find definitive answers.
What's the correct way to calculate beam damage in an EveryFrameCombatPlugin?
if you're using advance with a float "amount", I've seen in different scripts:
beam.getDamage().computeDamageDealt(amount);
beam.getWeapon().getDamage().getDamage() * amount;
beam.getDamage().getDamage() * amount;
Or intervals and checking every 0.1f with getDerivedStats:
float interval_dmg = beam.getWeapon().getDerivedStats().getDps() / 10f;
I've seen one post earlier saying computeDamageDealt is unreliable, so don't use that. I've seen others saying the getDamage might not be taking into account skills etc either? So.... very confused!
Also, separate to the above but related, if you want to modify the damage of a beam is this the correct way to do that below? Some of the skill e.g. RangedSpecialization seem to do it this way.
DamageAPI damage = beam.getDamage();
String id = "damage_increase";
float DAMAGE_BONUS = 30f;
damage.getModifier().modifyPercent(id, DAMAGE_BONUS);
setMultiplier() also seems to manipulate the final damage but I wasn't sure of the differences there, is that meant to be related to different damage types vs armor, shields, etc?
Appreciate any answers to the above!
