[BACK]Return to misc.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / games / monop

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/games/monop/misc.c between version 1.22 and 1.23

version 1.22, 2011/12/01 07:05:52 version 1.23, 2012/06/19 05:35:32
Line 52  static void is_monop(MON *, int);
Line 52  static void is_monop(MON *, int);
  * "yes or "no" answer is gotten.   * "yes or "no" answer is gotten.
  */   */
 int  int
 getyn(prompt)  getyn(const char *prompt)
         const char *prompt;  
 {  {
         int com;          int com;
   
Line 68  getyn(prompt)
Line 67  getyn(prompt)
  *      This routine tells the player if he's out of money.   *      This routine tells the player if he's out of money.
  */   */
 void  void
 notify()  notify(void)
 {  {
         if (cur_p->money < 0)          if (cur_p->money < 0)
                 printf("That leaves you $%d in debt\n", -cur_p->money);                  printf("That leaves you $%d in debt\n", -cur_p->money);
Line 84  notify()
Line 83  notify()
  *      This routine switches to the next player   *      This routine switches to the next player
  */   */
 void  void
 next_play()  next_play(void)
 {  {
         player = (player + 1) % num_play;          player = (player + 1) % num_play;
         cur_p = &play[player];          cur_p = &play[player];
Line 96  next_play()
Line 95  next_play()
  * given prompt.   * given prompt.
  */   */
 int  int
 get_int(prompt)  get_int(const char *prompt)
         const char *prompt;  
 {  {
         long num;          long num;
         char *sp;          char *sp;
Line 126  get_int(prompt)
Line 124  get_int(prompt)
  *      This routine sets the monopoly flag from the list given.   *      This routine sets the monopoly flag from the list given.
  */   */
 void  void
 set_ownlist(pl)  set_ownlist(int pl)
         int pl;  
 {  {
         int num;                /* general counter              */          int num;                /* general counter              */
         MON *orig;              /* remember starting monop ptr  */          MON *orig;              /* remember starting monop ptr  */
Line 238  set_ownlist(pl)
Line 235  set_ownlist(pl)
  *      This routine sets things up as if it is a new monopoly   *      This routine sets things up as if it is a new monopoly
  */   */
 static void  static void
 is_monop(mp, pl)  is_monop(MON *mp, int pl)
         MON *mp;  
         int pl;  
 {  {
         int i;          int i;
   
Line 255  is_monop(mp, pl)
Line 250  is_monop(mp, pl)
  *      This routine sets things up as if it is no longer a monopoly   *      This routine sets things up as if it is no longer a monopoly
  */   */
 void  void
 is_not_monop(mp)  is_not_monop(MON *mp)
         MON *mp;  
 {  {
         int i;          int i;
   
Line 270  is_not_monop(mp)
Line 264  is_not_monop(mp)
  *      This routine gives a list of the current player's routine   *      This routine gives a list of the current player's routine
  */   */
 void  void
 list()  list(void)
 {  {
         printhold(player);          printhold(player);
 }  }
Line 279  list()
Line 273  list()
  *      This routine gives a list of a given players holdings   *      This routine gives a list of a given players holdings
  */   */
 void  void
 list_all()  list_all(void)
 {  {
         int pl;          int pl;
   
Line 292  list_all()
Line 286  list_all()
  *      This routine gives the players a chance before it exits.   *      This routine gives the players a chance before it exits.
  */   */
 void  void
 quit()  quit(void)
 {  {
         putchar('\n');          putchar('\n');
   

Legend:
Removed from v.1.22  
changed lines
  Added in v.1.23

CVSweb <webmaster@jp.NetBSD.org>