- don't truncate unreasonably long player names when bidding;
- don't allow players to bid more cash than they have.
-/* $NetBSD: prop.c,v 1.15 2008/02/20 05:08:46 dholland Exp $ */
+/* $NetBSD: prop.c,v 1.16 2008/02/23 22:17:02 dholland Exp $ */
/*
* Copyright (c) 1980, 1993
/*
* Copyright (c) 1980, 1993
#if 0
static char sccsid[] = "@(#)prop.c 8.1 (Berkeley) 5/31/93";
#else
#if 0
static char sccsid[] = "@(#)prop.c 8.1 (Berkeley) 5/31/93";
#else
-__RCSID("$NetBSD: prop.c,v 1.15 2008/02/20 05:08:46 dholland Exp $");
+__RCSID("$NetBSD: prop.c,v 1.16 2008/02/23 22:17:02 dholland Exp $");
#endif
#endif /* not lint */
#endif
#endif /* not lint */
{
static bool in[MAX_PL];
int i, num_in, cur_max;
{
static bool in[MAX_PL];
int i, num_in, cur_max;
int cur_bid;
printf("\nSo it goes up for auction. Type your bid after your name\n");
int cur_bid;
printf("\nSo it goes up for auction. Type your bid after your name\n");
printf("You must bid higher than %d "
"to stay in\n", cur_max);
printf("(bid of 0 drops you out)\n");
printf("You must bid higher than %d "
"to stay in\n", cur_max);
printf("(bid of 0 drops you out)\n");
+ } else if (cur_bid > play[i].money) {
+ printf("You can't bid more than your cash ($%d)\n",
+ play[i].money);
+ cur_bid = -1;
}
} while (cur_bid != 0 && cur_bid <= cur_max);
cur_max = (cur_bid ? cur_bid : cur_max);
}
} while (cur_bid != 0 && cur_bid <= cur_max);
cur_max = (cur_bid ? cur_bid : cur_max);