Update pages to follow new card flow
This commit is contained in:
@@ -56,16 +56,20 @@ namespace UI.CardSystem.StateMachine
|
||||
protected override void OnDragStartedHook()
|
||||
{
|
||||
base.OnDragStartedHook();
|
||||
|
||||
// Always emit the generic drag started event - consumers can decide what to do
|
||||
context?.NotifyDragStarted();
|
||||
|
||||
string current = GetCurrentStateName();
|
||||
|
||||
if (current == "PendingFaceDownState")
|
||||
{
|
||||
// Notify AlbumViewPage to assign data & flip
|
||||
var albumPage = FindObjectOfType<AlbumViewPage>();
|
||||
if (albumPage != null)
|
||||
// Let the state handle the flip transition
|
||||
var pendingState = GetStateComponent<States.CardPendingFaceDownState>("PendingFaceDownState");
|
||||
if (pendingState != null)
|
||||
{
|
||||
albumPage.HandlePendingCardDragStart(this);
|
||||
pendingState.OnDragStarted();
|
||||
}
|
||||
// State change will be triggered by album page after data assignment
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user