Merge branch 'crabman/dependency-fix' into 'master'

Update outdated dependency

See merge request veloren/veloren!4393
This commit is contained in:
crabman
2024-03-23 20:37:19 +00:00

View File

@ -229,7 +229,12 @@ impl Attack {
.clamp(0.0, 1.0);
let raw_damage_reduction =
Damage::compute_damage_reduction(Some(damage), target.inventory, target.stats, msm);
(1.0 - attacker_penetration) * raw_damage_reduction
if raw_damage_reduction >= 1.0 {
raw_damage_reduction
} else {
(1.0 - attacker_penetration) * raw_damage_reduction
}
} else {
0.0
}