Exemplo n.º 1
0
    protected void BtnTrade_OnClick(object sender, EventArgs e)
    {
        try
        {
            var userCards  = UcPlayer.SelectedCards.ToList();
            var tableCards = SelectedCards.ToList();

            GameData.TradeCards(UserData.User, userCards, tableCards);
            GameData.Save();

            Response.Redirect(Request.Url.ToString());
        }
        catch (Exception ex)
        {
            //TODO: Show error message.
        }
    }