Kind of working booster packs

This commit is contained in:
Michal Adam Pikulski
2025-10-20 13:45:56 +02:00
parent 32f726d229
commit 83b5c8994d
12 changed files with 1244 additions and 299 deletions

View File

@@ -154,7 +154,12 @@ namespace AppleHills.UI.CardSystem
if (_hasUnseenCards)
{
_hasUnseenCards = false;
UpdateBoosterVisibility();
}
// Hide the backpack button when entering menu
if (backpackButton != null)
{
backpackButton.gameObject.SetActive(false);
}
}
else if (_pageController.CurrentPage == mainMenuPage)
@@ -176,8 +181,8 @@ namespace AppleHills.UI.CardSystem
}
else
{
if (backpackIcon != null)
backpackIcon.SetActive(false);
if (backpackButton != null)
backpackButton.gameObject.SetActive(false);
}
// Update menu if it's the main menu page
@@ -193,13 +198,21 @@ namespace AppleHills.UI.CardSystem
/// </summary>
private void ShowOnlyBackpackIcon()
{
if (backpackIcon != null)
backpackIcon.SetActive(true);
if (backpackButton != null)
{
backpackButton.gameObject.SetActive(true);
// Update booster notification visibility
UpdateBoosterVisibility();
// Update notification visibility based on booster count
bool hasBooters = _cardManager != null && _cardManager.GetBoosterPackCount() > 0;
// Show notification dot if there are boosters or unseen cards
if (boosterNotificationDot != null)
{
boosterNotificationDot.gameObject.SetActive(hasBooters || _hasUnseenCards);
}
}
}
/// <summary>
/// Opens the album view page
/// </summary>