示例#1
0
        public void PushBetMove(Models.BetMove move)
        {
            int bet = move.GetAmount();

            if (bet > 0)
            {
                bet_sound.Play();
            }
            else
            {
                ChecksSound.Play();
            }
            potSizeInt        += bet;
            PotSizeLbl.Content = "Pot Size: $" + potSizeInt;
            if (!ReplayMode)
            {
                if (move.GetBettingPlayer().Equals(manager.GetProfile().username))
                {
                    playerCredit  -= bet;
                    playerBet     += bet;
                    credit.Content = "Credit: $" + playerCredit;
                    betted.Content = "$" + playerBet;
                    return;
                }
            }

            foreach (PlayerAtTable player in players)
            {
                if (player.Username.Equals(move.GetBettingPlayer()))
                {
                    player.Bet(move.GetAmount());
                    return;
                }
            }
        }
示例#2
0
        public void ShowAvatar()
        {
            Models.ClientUserProfile prof = manager.GetProfile();

            BitmapImage image = manager.getAvatar();

            if (image != null)
            {
                user_avatar.Source = image;
            }
            username.Content = prof.username;
            credit.Content   = "Credit: $" + prof.credit;
        }
示例#3
0
 public void RefreshStatus()
 {
     Models.ClientUserProfile prof = manager.GetProfile();
     this.credit.Content   = "Credit: $" + prof.credit;
     this.username.Content = "Hello " + prof.username;
 }