arogue5: update the score list before prompting to exit.

This commit is contained in:
John "Elwin" Edwards 2012-08-11 20:58:24 +00:00
parent 8c27cf1402
commit 4d11069d9c

View file

@ -472,6 +472,13 @@ short monst;
} }
} }
fseek(outf, 0L, 0);
/*
* Update the list file
*/
scoreout(top_ten, outf);
fclose(outf);
/* /*
* SCOREIT -- rogue -s option. Never started curses if this option. * SCOREIT -- rogue -s option. Never started curses if this option.
* UPDATE -- network scoring update. Never started curses if this option. * UPDATE -- network scoring update. Never started curses if this option.
@ -557,19 +564,14 @@ short monst;
else printf("\n"); else printf("\n");
} }
} }
/* if (prflags == EDITSCORE) endwin(); */ /* End editing windowing */
}
if ((flags != SCOREIT) && (flags != UPDATE)) { if ((flags != SCOREIT) && (flags != UPDATE)) {
printf("\n[Press return to exit]"); printf("\n[Press return to exit]");
fflush(stdout); fflush(stdout);
fgets(prbuf,80,stdin); fgets(prbuf,80,stdin);
} }
/* if (prflags == EDITSCORE) endwin(); */ /* End editing windowing */
}
fseek(outf, 0L, 0);
/*
* Update the list file
*/
scoreout(top_ten, outf);
fclose(outf);
} }
void writelog(unsigned long amount, int flags, short monst) { void writelog(unsigned long amount, int flags, short monst) {