public bool PlaceBet(int BetAmount, string AvengerToWin, decimal Test) { this.MyBet = new Bets() { Amount = BetAmount, Avenger = AvengerToWin, Bettor = this, odds = Test }; if (BetAmount <= Cash) { MyLabel2.Text = this.Name + " bets " + BetAmount + " dollars on " + AvengerToWin; this.UpdateLabels(); return(true); } else { MessageBox.Show(Name + " does not have enough to cover that bet "); this.MyBet = null; return(false); } }
public void ClearBet() { MyBet = null; MyLabel2.Text = Name + " hasn't placed a bet"; }