X-Git-Url: https://jasonwoof.com/gitweb/?p=vor.git;a=blobdiff_plain;f=score.c;h=30d30a5eb4c479124b0f83fb296bd45b92368745;hp=07c52a55c4d051afc9aea5510a3b079235fc1066;hb=19f8eb7a835a2b084010a8deb8f3d200f995559d;hpb=8c4076c17519e9f5a2bfc45fe1b885d9ce806b54 diff --git a/score.c b/score.c index 07c52a5..30d30a5 100644 --- a/score.c +++ b/score.c @@ -31,26 +31,27 @@ #include "score.h" // High score table +// below are the defaults (when there's no high score file) in miliseconds struct highscore g_scores[2][N_SCORES] = { { - {1*60*1000,"-"}, - {45*1000,"-"}, - {30*1000,"-"}, - {20*1000,"-"}, - {10*1000,"-"}, - {7*1000,"-"}, - {5*1000,"-"}, - {3*1000,"-"} + {120000,"-"}, + {105000,"-"}, + { 90000,"-"}, + { 75000,"-"}, + { 60000,"-"}, + { 50000,"-"}, + { 40000,"-"}, + { 30000,"-"} }, { - {1*60*1000,"-"}, - {45*1000,"-"}, - {30*1000,"-"}, - {20*1000,"-"}, - {10*1000,"-"}, - {7*1000,"-"}, - {5*1000,"-"}, - {3*1000,"-"} + {120000,"-"}, + {105000,"-"}, + { 90000,"-"}, + { 75000,"-"}, + { 60000,"-"}, + { 50000,"-"}, + { 40000,"-"}, + { 30000,"-"} } }; @@ -143,7 +144,7 @@ snprintscore(char *s, size_t n, int score) if(min) { return snprintf(s, n, "%2d:%.2d.%d", min, sec, tenths); } else { - return snprintf(s, n, "%2d.%d", sec, tenths); + return snprintf(s, n, " %2d.%d", sec, tenths); } } @@ -192,7 +193,7 @@ process_score_input(SDL_keysym *key) if(key->sym == SDLK_BACKSPACE) { if(n > 0) name[--n]=0; } else { - if(key->sym == SDLK_RETURN) { + if(key->sym == SDLK_RETURN || key->sym == SDLK_KP_ENTER) { SDL_EnableUNICODE(0); cur_score = -1; if(n == 0) {