comparison urogue/rip.c @ 277:1bbdd13ec585

UltraRogue: fix Y2K bug on tombstone. Years were being displayed as "191XX" instead of "20XX".
author John "Elwin" Edwards
date Mon, 11 Sep 2017 17:46:42 -0400
parents 4ab49e42dd6a
children 0250220d8cdd
comparison
equal deleted inserted replaced
276:4573b355cdc1 277:1bbdd13ec585
167 mvaddstr(14, 28 - ((int)(strlen(whoami) + 1) / 2), whoami); 167 mvaddstr(14, 28 - ((int)(strlen(whoami) + 1) / 2), whoami);
168 sprintf(buf, "%d+%ld Points", pstats.s_lvl, pstats.s_exp); 168 sprintf(buf, "%d+%ld Points", pstats.s_lvl, pstats.s_exp);
169 mvaddstr(15, 28 - ((int)(strlen(buf) + 1) / 2), buf); 169 mvaddstr(15, 28 - ((int)(strlen(buf) + 1) / 2), buf);
170 killer = killname(monst,buf); 170 killer = killname(monst,buf);
171 mvaddstr(17, 28 - ((int)(strlen(killer) + 1) / 2), killer); 171 mvaddstr(17, 28 - ((int)(strlen(killer) + 1) / 2), killer);
172 mvaddstr(18, 28, (sprintf(prbuf, "%2d", lt->tm_year), prbuf)); 172 mvaddstr(18, 26, (sprintf(prbuf, "%4d", 1900+lt->tm_year), prbuf));
173 move(LINES - 1, 0); 173 move(LINES - 1, 0);
174 174
175 mvaddstr(LINES - 1, 0, retstr); 175 mvaddstr(LINES - 1, 0, retstr);
176 176
177 while ((c = readcharw(stdscr)) != '\n' && c != '\r') 177 while ((c = readcharw(stdscr)) != '\n' && c != '\r')