Fixed AddGifterBotToMaps()

This commit is contained in:
Chomp
2025-04-01 13:01:52 +01:00
parent 065c6b34d1
commit 4ecf1b2253
2 changed files with 2 additions and 2 deletions
@@ -226,6 +226,6 @@ public record Locations
{
var classProps = typeof(Locations).GetProperties().Where(p => p.PropertyType == typeof(Eft.Common.Location) && p.Name != "Item");
_locationDictionaryCache = classProps
.ToDictionary(propertyInfo => propertyInfo.Name, propertyInfo => propertyInfo.GetValue(this, null) as Eft.Common.Location);
.ToDictionary(propertyInfo => propertyInfo.Name, propertyInfo => propertyInfo.GetValue(this, null) as Eft.Common.Location, StringComparer.OrdinalIgnoreCase);
}
}
@@ -1091,7 +1091,7 @@ public class SeasonalEventService(
var maps = _databaseService.GetLocations().GetDictionary();
foreach (var gifterMapSettings in gifterSettings)
{
if (!maps.TryGetValue(gifterMapSettings.Map, out var mapData))
if (!maps.TryGetValue(_databaseService.GetLocations().GetMappedKey(gifterMapSettings.Map), out var mapData))
{
_logger.Warning($"AddGifterBotToMaps() Map not found {gifterMapSettings.Map}");