long-war-2 / lwotc

Port of Long War 2 to XCOM 2's War of the Chosen expansion
342 stars 89 forks source link

Fleche Graze Damage #771

Closed Clibanarius closed 4 years ago

Clibanarius commented 4 years ago

Shinobi Fleche seems to be doing a lot of damage on grazes. We're speculating that it's because it's only halving the damage of the base sword attack and not the end damage bonus from the movement. Since Fleche does one extra damage every, like, 3 or 4 tiles distance from the starting point, it's doing the 3, 4, 5, whatever, damage of the Fleche flat. So a hit that would do 12 damage is doing 8 grazed instead of 6.

Clibanarius commented 4 years ago

Good example here of the end result: https://youtu.be/heZWkuXBrwM?t=867

Anthogator commented 4 years ago

I've looked through the various files that mention fleche, and it looks to me like forcing the graze roll to add the bonus damage before multiplying that total by 0.5 in X2Effect_ApplyAltWeaponDamage.uc would be the best solution. Currently the WeaponDamage float is supposed to calculate it... WeaponDamage = BaseDamageValue.Damage + ExtraDamageValue.Damage + BonusEffectDamageValue.Damage + AmmoDamageValue.Damage + UpgradeDamageValue.Damage; But it doesn't appear to be working. I suspect this is because the added damage from fleche is not coded as ExtraDamageValue or BonusEffectDamageValue, but is instead coded as a deadeye attack in the X2Ability_PerkPackAbilitySet2.uc file. I'm not sure the best way to go about fixing this. Anything that forced the fleche damage into this calculation would mean it also would have to change the fleche ability template to stop adding damage by itself...

Alternatively, would it be possible to force the X2Ability_PerkPackAbilitySet2.uc template to make it check if the attack is a graze?

pledbrook commented 4 years ago

I think this can only be fixed in the highlander. The graze damage reduction is applied before all bonus weapon damage is added. That makes bonus weapon damage of all sorts (include Blademaster for example) that much stronger.

pledbrook commented 4 years ago

Fixed in this commit