void Score::DrawScoreCard(void) { char *gameName[] = { "Pool", "CAD", "Gear", "Keep Awake"}; FsGetWindowSize(winWid, winHei); glRasterPos2d(0.0,(double)(winHei-1)); glDrawPixels(scoreCard.wid,scoreCard.hei,GL_RGBA,GL_UNSIGNED_BYTE,scoreCard.rgba); char msg[256]; glColor3ub(0, 0, 0); for (int i=0; i<4; i++) { sprintf(msg, "Game %d: %s", i+1, gameName[i]); glRasterPos2d(175, 175+i*100); YsGlDrawFontBitmap16x24(msg); sprintf(msg, "%d trials, %s", gameCount[i], gamePassed[i]?"Passed":"Failed"); glRasterPos2d(225, 215+i*100); YsGlDrawFontBitmap16x24(msg); } }
void GameMenu::DrawKeyOption (void) { glColor3ub(100, 255, 0); glRasterPos2d(159,321); YsGlDrawFontBitmap20x32 (" D I N N E R"); glRasterPos2d(161,321); YsGlDrawFontBitmap20x32 (" D I N N E R"); glRasterPos2d(159,319); YsGlDrawFontBitmap20x32 (" D I N N E R"); glRasterPos2d(161,321); YsGlDrawFontBitmap20x32 (" D I N N E R"); glRasterPos2d(158,320); YsGlDrawFontBitmap20x32 (" D I N N E R"); glRasterPos2d(162,320); YsGlDrawFontBitmap20x32 (" D I N N E R"); glRasterPos2d(160,318); YsGlDrawFontBitmap20x32 (" D I N N E R"); glRasterPos2d(160,322); YsGlDrawFontBitmap20x32 (" D I N N E R"); glColor3ub(0, 0, 0); glRasterPos2d(160,250); YsGlDrawFontBitmap20x32 ("D O N'T b e"); glRasterPos2d(159,250); YsGlDrawFontBitmap20x32 ("D O N'T b e"); glRasterPos2d(161,250); YsGlDrawFontBitmap20x32 ("D O N'T b e"); glRasterPos2d(160,249); YsGlDrawFontBitmap20x32 ("D O N'T b e"); glRasterPos2d(160,251); YsGlDrawFontBitmap20x32 ("D O N'T b e"); glRasterPos2d(160,320); YsGlDrawFontBitmap20x32 (" D I N N E R"); glRasterPos2d(159,320); YsGlDrawFontBitmap20x32 (" D I N N E R"); glRasterPos2d(161,320); YsGlDrawFontBitmap20x32 (" D I N N E R"); glRasterPos2d(160,319); YsGlDrawFontBitmap20x32 (" D I N N E R"); glRasterPos2d(160,321); YsGlDrawFontBitmap20x32 (" D I N N E R"); glColor3ub(255, 125, 40); glRasterPos2d(260,420); YsGlDrawFontBitmap20x28 ("D:"); glColor3ub(255, 255, 40); glRasterPos2d(310,420); YsGlDrawFontBitmap16x20 ("Default Control"); glColor3ub(255, 125, 40); glRasterPos2d(260,470); YsGlDrawFontBitmap20x28 ("R:"); glColor3ub(255, 255, 40); glRasterPos2d(310,470); YsGlDrawFontBitmap16x20 ("Remapped Control"); glColor3ub(255, 125, 40); glRasterPos2d(260,520); YsGlDrawFontBitmap16x24 ("Esc:"); glColor3ub(255, 255, 40); glRasterPos2d(340,520); YsGlDrawFontBitmap16x20 ("end the game"); glColor3ub(255, 255, 255); glRasterPos2d(520,25); YsGlDrawFontBitmap6x10 ("24-780 Engineering Computation Final Project"); glRasterPos2d(600,45); YsGlDrawFontBitmap6x10 ("Copyright 2011 Fall"); }