using System.Collections; using System.Collections.Generic; using AppleHills.Data.CardSystem; using Core; using Data.CardSystem; using Pixelplacement; using UI.Core; using UnityEngine; using UnityEngine.UI; namespace UI.CardSystem { /// /// UI page for opening booster packs and displaying the cards obtained. /// public class BoosterOpeningPage : UIPage { [Header("UI Elements")] [SerializeField] private GameObject boosterPackObject; [SerializeField] private RectTransform cardRevealContainer; // This should have a HorizontalLayoutGroup component with pre-populated card backs [SerializeField] private GameObject cardPrefab; [SerializeField] private Button openBoosterButton; [SerializeField] private Button continueButton; [SerializeField] private CanvasGroup canvasGroup; [Header("Navigation")] [SerializeField] private Button backButton; [Header("Animation Settings")] [SerializeField] private float cardRevealDelay = 0.3f; [SerializeField] private float flipAnimationDuration = 0.5f; // State tracking private enum OpeningState { BoosterReady, CardBacksVisible, CardsRevealing, CardsRevealed, MovingToBackpack, Completed } private OpeningState _currentState = OpeningState.BoosterReady; private List _revealedCards = new List(); private List