Skip to content

Commit

Permalink
Temporary fix for broken Invictus DNA strings (#1669) #patch
Browse files Browse the repository at this point in the history
Sentry event: d7000a22c8974f3993523b34db30aa2b
  • Loading branch information
IhateTrains authored Dec 27, 2023
1 parent ed2ee89 commit 9bb9f56
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions ImperatorToCK3/Imperator/Characters/PortraitData.cs
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,12 @@ public PortraitData(string dnaString, GenesDB genesDB, string ageSexString = "ma
continue;
}

// Temporary fix for broken Invictus DNA strings which don't have a value for the headgear gene.
// TODO: verify if still require for Invictus version higher than the original pre-hotfix 1.7

Check warning on line 87 in ImperatorToCK3/Imperator/Characters/PortraitData.cs

View workflow job for this annotation

GitHub Actions / Upload development build (linux-x64)

TODO verify if still require for Invictus version higher than the original pre-hotfix 1.7 (https://github.com/meziantou/Meziantou.Analyzer/blob/main/docs/Rules/MA0026.md)

Check warning on line 87 in ImperatorToCK3/Imperator/Characters/PortraitData.cs

View workflow job for this annotation

GitHub Actions / add_release_archive (linux-x64)

TODO verify if still require for Invictus version higher than the original pre-hotfix 1.7 (https://github.com/meziantou/Meziantou.Analyzer/blob/main/docs/Rules/MA0026.md)

Check warning on line 87 in ImperatorToCK3/Imperator/Characters/PortraitData.cs

View workflow job for this annotation

GitHub Actions / add_release_archive (osx-arm64)

TODO verify if still require for Invictus version higher than the original pre-hotfix 1.7 (https://github.com/meziantou/Meziantou.Analyzer/blob/main/docs/Rules/MA0026.md)

Check warning on line 87 in ImperatorToCK3/Imperator/Characters/PortraitData.cs

View workflow job for this annotation

GitHub Actions / Upload development build (win-x64)

TODO verify if still require for Invictus version higher than the original pre-hotfix 1.7 (https://github.com/meziantou/Meziantou.Analyzer/blob/main/docs/Rules/MA0026.md)

Check warning on line 87 in ImperatorToCK3/Imperator/Characters/PortraitData.cs

View workflow job for this annotation

GitHub Actions / run_test_conversions (https://mega.nz/file/id90lRYD#4OBL6N6_87-Nu28wNssm-O-3jmxli0iFzOtI7XVdN1E)

TODO verify if still require for Invictus version higher than the original pre-hotfix 1.7 (https://github.com/meziantou/Meziantou.Analyzer/blob/main/docs/Rules/MA0026.md)

Check warning on line 87 in ImperatorToCK3/Imperator/Characters/PortraitData.cs

View workflow job for this annotation

GitHub Actions / run_test_conversions (https://mega.nz/file/TR13kB7D#QWT2yFzoS3rSIu9-EkUEdcc-X8jJnhZdXbJvw9jC-dg)

TODO verify if still require for Invictus version higher than the original pre-hotfix 1.7 (https://github.com/meziantou/Meziantou.Analyzer/blob/main/docs/Rules/MA0026.md)

Check warning on line 87 in ImperatorToCK3/Imperator/Characters/PortraitData.cs

View workflow job for this annotation

GitHub Actions / add_release_archive (win-x64)

TODO verify if still require for Invictus version higher than the original pre-hotfix 1.7 (https://github.com/meziantou/Meziantou.Analyzer/blob/main/docs/Rules/MA0026.md)

Check warning on line 87 in ImperatorToCK3/Imperator/Characters/PortraitData.cs

View workflow job for this annotation

GitHub Actions / run_test_conversions (https://mega.nz/file/yd1nAZpB#6pXqexexEAXgE04Kll1XYwz_IhRPr42juVIJQ4uKXM8)

TODO verify if still require for Invictus version higher than the original pre-hotfix 1.7 (https://github.com/meziantou/Meziantou.Analyzer/blob/main/docs/Rules/MA0026.md)

Check warning on line 87 in ImperatorToCK3/Imperator/Characters/PortraitData.cs

View workflow job for this annotation

GitHub Actions / run_test_conversions (https://mega.nz/file/zQ0wDKya#eiFQCiJ2sjTaolAJGnfQ0_0OS2Q1kf48dIGDlrEoJ9I)

TODO verify if still require for Invictus version higher than the original pre-hotfix 1.7 (https://github.com/meziantou/Meziantou.Analyzer/blob/main/docs/Rules/MA0026.md)
if (gene.Id == "headgear") {
continue;
}

var geneTemplateByteIndex = geneIndex.Value * 4;
var geneTemplateIndex = (uint)decodedDnaStr[geneTemplateByteIndex];
var geneTemplateRecessiveIndex = (uint)decodedDnaStr[geneTemplateByteIndex + 2];
Expand Down

0 comments on commit 9bb9f56

Please sign in to comment.