Skip to content

Commit

Permalink
store
Browse files Browse the repository at this point in the history
  • Loading branch information
MegaPiggy committed Aug 25, 2024
1 parent 7840165 commit 9528ebd
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions Winch/Patches/API/ActiveAbilityInfoPanelPatcher.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,19 @@ public static bool ActiveAbilityInfoPanel_RefreshUI_Prefix(ActiveAbilityInfoPane
{
if (spatialItemData != null && spatialItemData is IAbilityItemData abilityItemData)
{
__instance.abilityMode = abilityItemData.AbilityMode;
if (abilityItemData.QualityIcon != null)
var abilityMode = abilityItemData.AbilityMode;
__instance.abilityMode = abilityMode;

var qualityIcon = abilityItemData.QualityIcon;
if (qualityIcon != null)
{
__instance.qualityIcon.sprite = abilityItemData.QualityIcon;
__instance.qualityIcon.sprite = qualityIcon;
}
else
{
__instance.qualityIcon.sprite = __instance.GetSpriteForAbilityMode(abilityItemData.AbilityMode);
__instance.qualityIcon.sprite = __instance.GetSpriteForAbilityMode(abilityMode);
}

__instance.Show();
__instance.RefreshItemNameField(spatialItemData);
__instance.UpdateCatchableSpecies();
Expand Down

0 comments on commit 9528ebd

Please sign in to comment.