@@ -39,7 +39,7 @@ class mod_zone_difficulty_unitscript : public UnitScript
39
39
bool nerfInDuel = sZoneDifficulty ->ShouldNerfInDuels (target);
40
40
41
41
// Check if the map of the target is subject of a nerf at all OR if the target is subject of a nerf in a duel
42
- if (sZoneDifficulty ->NerfInfo . find (mapId) != sZoneDifficulty -> NerfInfo . end ( ) || nerfInDuel)
42
+ if (sZoneDifficulty ->ShouldNerfMap (mapId) || nerfInDuel)
43
43
{
44
44
if (SpellInfo const * spellInfo = aura->GetSpellInfo ())
45
45
{
@@ -152,7 +152,7 @@ class mod_zone_difficulty_unitscript : public UnitScript
152
152
uint32 mapId = target->GetMapId ();
153
153
bool nerfInDuel = sZoneDifficulty ->ShouldNerfInDuels (target);
154
154
// Check if the map of the target is subject of a nerf at all OR if the target is subject of a nerf in a duel
155
- if (sZoneDifficulty ->NerfInfo . find (mapId) != sZoneDifficulty -> NerfInfo . end ( ) || sZoneDifficulty ->ShouldNerfInDuels (target))
155
+ if (sZoneDifficulty ->ShouldNerfMap (mapId) || sZoneDifficulty ->ShouldNerfInDuels (target))
156
156
{
157
157
// This check must be first and skip the rest to override everything else.
158
158
if (spellInfo)
@@ -255,7 +255,7 @@ class mod_zone_difficulty_unitscript : public UnitScript
255
255
}
256
256
}
257
257
258
- if (sZoneDifficulty ->NerfInfo . find (mapId) != sZoneDifficulty -> NerfInfo . end ( ) && matchingPhase != -1 )
258
+ if (sZoneDifficulty ->ShouldNerfMap (mapId) && matchingPhase != -1 )
259
259
{
260
260
int8 mode = sZoneDifficulty ->NerfInfo [mapId][matchingPhase].Enabled ;
261
261
Map* map = target->GetMap ();
@@ -354,7 +354,7 @@ class mod_zone_difficulty_unitscript : public UnitScript
354
354
}
355
355
}
356
356
357
- if (sZoneDifficulty ->NerfInfo . find (mapId) != sZoneDifficulty -> NerfInfo . end ( ) && matchingPhase != -1 )
357
+ if (sZoneDifficulty ->ShouldNerfMap (mapId) && matchingPhase != -1 )
358
358
{
359
359
int8 mode = sZoneDifficulty ->NerfInfo [mapId][matchingPhase].Enabled ;
360
360
Map* map = target->GetMap ();
@@ -417,7 +417,7 @@ class mod_zone_difficulty_unitscript : public UnitScript
417
417
uint32 mapId = target->GetMapId ();
418
418
uint32 phaseMask = target->GetPhaseMask ();
419
419
int matchingPhase = sZoneDifficulty ->GetLowestMatchingPhase (mapId, phaseMask);
420
- if (sZoneDifficulty ->NerfInfo . find (mapId) != sZoneDifficulty -> NerfInfo . end ( ) && matchingPhase != -1 )
420
+ if (sZoneDifficulty ->ShouldNerfMap (mapId) && matchingPhase != -1 )
421
421
{
422
422
int8 mode = sZoneDifficulty ->NerfInfo [mapId][matchingPhase].Enabled ;
423
423
Map* map = target->GetMap ();
0 commit comments