public async Task OnLoadGame(ClientStateMachine stateMachine) { StateMachine = stateMachine; ViewCallback.SetUIState(stateMachine.UiState); await AnimateAllCardsBackToDeck(); this.Reset(); // this reletive order matters -- you want all cards belonging to the deck when this is run MainPage.Current.AppBar.IsOpen = false; }
public async Task OnNewGame(ClientStateMachine stateMachine) { StateMachine = stateMachine; ViewCallback.SetUIState(stateMachine.UiState); await AnimateAllCardsBackToDeck(); this.Reset(); // this reletive order matters -- you want all cards belonging to the deck when this is run await PickCard("Pick a card by touching (clicking) it. Low card deals!"); MainPage.Current.AppBar.IsOpen = false; }
public async Task Initialize(Deck deck, ClientStateMachine stateMachine) { this.Deck = deck; await AddCardsToGrid(); StateMachine = stateMachine; if (StateMachine != null) { Hfs = stateMachine.HandsFromService; ViewCallback.SetUIState(stateMachine.UiState); } }
public void InitializeAsync(Deck deck, ClientStateMachine stateMachine) { this.Deck = deck; StateMachine = stateMachine; #pragma warning disable 1998, 4014 AddCardsToGrid(); #pragma warning restore 1998, 4014 if (StateMachine != null) { ViewCallback.SetUIState(stateMachine.UiState); } PlayerSetScoreControl.HideAsync(); }