X-Git-Url: https://git.jsancho.org/?a=blobdiff_plain;f=Source%2FGameDraw.cpp;h=a346f23f2b519a1c353cefad412bc58f5f783e41;hb=e08372a2095837a0b951ccb68c3499ef67c1a827;hp=7ee322eb48eaec9ee32858938a9170cf58fb68e6;hpb=64560867a9b6486d601784a2fe4ba6149d31b7aa;p=lugaru.git diff --git a/Source/GameDraw.cpp b/Source/GameDraw.cpp index 7ee322e..a346f23 100644 --- a/Source/GameDraw.cpp +++ b/Source/GameDraw.cpp @@ -62,7 +62,7 @@ extern float motionbluramount; extern bool isclient; extern bool alwaysblur; extern bool velocityblur; -extern bool debugmode; +extern bool devtools; extern int mainmenu; extern int bloodtoggle; extern int difficulty; @@ -1051,9 +1051,9 @@ int Game::DrawGLScene(StereoSide side) if (!tutoriallevel && !winfreeze && !Dialog::inDialog() && !mainmenu) { if (campaign) { if (scoreadded) - sprintf (string, "Score: %d", (int)accountactive->getCampaignScore()); + sprintf (string, "Score: %d", (int)Account::active().getCampaignScore()); else - sprintf (string, "Score: %d", (int)accountactive->getCampaignScore() + (int)bonustotal); + sprintf (string, "Score: %d", (int)Account::active().getCampaignScore() + (int)bonustotal); } if (!campaign) sprintf (string, "Score: %d", (int)bonustotal); @@ -1150,7 +1150,7 @@ int Game::DrawGLScene(StereoSide side) glColor4f(.5, .5, .5, 1); - if ((texttoggle || editorenabled) && debugmode && !mainmenu) { + if ((texttoggle || editorenabled) && devtools && !mainmenu) { sprintf (string, "The framespersecond is %d.", (int)(fps)); text->glPrint(10, 30, string, 0, .8, 1024, 768); @@ -1610,21 +1610,19 @@ int Game::DrawGLScene(StereoSide side) sprintf (string, "Score: %d", (int)(bonustotal - startbonustotal)); text->glPrintOutlined(1024 / 30, 768 * 6 / 8, string, 1, 2, 1024, 768); - if (campaign) - sprintf (string, "Press Escape or Space to continue"); - else - sprintf (string, "Press Escape to return to menu or Space to continue"); + sprintf (string, "Press Escape to return to menu or Space to continue"); text->glPrintOutlined(640 / 2 - strlen(string) * 5, 480 * 1 / 16, string, 1, 1, 640, 480); char temp[255]; for (int i = 0; i < 255; i++) string[i] = '\0'; - sprintf (temp, "Time: %d:", (int)(((int)leveltime - (int)(leveltime) % 60) / 60)); + int wontime = (int)round(wonleveltime); + sprintf (temp, "Time: %d:", int((wontime - wontime % 60) / 60)); strcat(string, temp); - if ((int)(leveltime) % 60 < 10) + if (wontime % 60 < 10) strcat(string, "0"); - sprintf (temp, "%d", (int)(leveltime) % 60); + sprintf (temp, "%d", wontime % 60); strcat(string, temp); text->glPrintOutlined(1024 / 30, 768 * 6 / 8 - 40, string, 1, 2, 1024, 768);