Skip to content

Commit

Permalink
Don't send pinned or locked items
Browse files Browse the repository at this point in the history
  • Loading branch information
Lacyway committed Jan 3, 2025
1 parent 1cc5226 commit 2f65806
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion Fika.Core/UI/Patches/ItemContext_Patch.cs
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,11 @@ private static void Prefix(ItemInfoInteractionsAbstractClass<EItemInfoButton> co
return;
}

if (item.PinLockState is EItemPinLockState.Pinned or EItemPinLockState.Locked) // Don't send pinned or locked items (who even does this?)
{
return;
}

// Check for GClass increments
Dictionary<string, DynamicInteractionClass> dynamicInteractions = Traverse.Create(contextInteractions)
.Field<Dictionary<string, DynamicInteractionClass>>("dictionary_0").Value;
Expand All @@ -87,7 +92,7 @@ private static void Prefix(ItemInfoInteractionsAbstractClass<EItemInfoButton> co
else
{
string itemName = attachedItem.ShortName.Localized();
string attachedItemText = FikaUIGlobals.ColorizeText(EColor.BLUE, itemName);
string attachedItemText = ColorizeText(EColor.BLUE, itemName);
NotificationManagerClass.DisplayMessageNotification(string.Format(LocaleUtils.ITEM_CONTAINS_BLACKLISTED.Localized(),
[itemText, attachedItemText]),
iconType: EFT.Communications.ENotificationIconType.Alert);
Expand Down

0 comments on commit 2f65806

Please sign in to comment.