Skip to content

Commit

Permalink
fix: to contains
Browse files Browse the repository at this point in the history
  • Loading branch information
dudantas committed Feb 25, 2025
1 parent 72ece5a commit 3d8b003
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/creatures/combat/combat.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2288,7 +2288,7 @@ void Combat::applyExtensions(const std::shared_ptr<Creature> &caster, const std:
uint16_t raceId = mType->info.raceid;

if (raceId == lowBlowRaceid) {
if (lowBlowCrits.find(raceId) == lowBlowCrits.end()) {
if (!lowBlowCrits.contains(raceId)) {
lowBlowCrits[raceId] = (lowBlowChance != 0 && uniform_random(1, 10000) <= lowBlowChance);
}
}
Expand All @@ -2310,7 +2310,7 @@ void Combat::applyExtensions(const std::shared_ptr<Creature> &caster, const std:

uint16_t raceId = mType->info.raceid;

if (!globalCritical && lowBlowCrits.find(raceId) != lowBlowCrits.end() && lowBlowCrits[raceId]) {
if (!globalCritical && lowBlowCrits.contains(raceId) && lowBlowCrits[raceId]) {
isTargetCritical = true;
}
}
Expand Down

0 comments on commit 3d8b003

Please # to comment.