void V_DrawBox(int x, int y, int w, int h) { int xs = bgp[0]->width; int ys = bgp[0]->height; int i, j; // top rows V_DrawPatch(x, y, &subscreen43, bgp[0]); // ul for(j = x+xs; j < x+w-xs; j += xs) // uc V_DrawPatch(j, y, &subscreen43, bgp[1]); V_DrawPatchShadowed(j, y, &subscreen43, bgp[2], NULL, 65536); // ur // middle rows for(i = y+ys; i < y+h-ys; i += ys) { V_DrawPatch(x, i, &subscreen43, bgp[3]); // cl for(j = x+xs; j < x+w-xs; j += xs) // cc V_DrawPatch(j, i, &subscreen43, bgp[4]); V_DrawPatchShadowed(j, i, &subscreen43, bgp[5], NULL, 65536); // cr } // bottom row V_DrawPatchShadowed(x, i, &subscreen43, bgp[6], NULL, 65536); for(j = x+xs; j < x+w-xs; j += xs) V_DrawPatchShadowed(j, i, &subscreen43, bgp[7], NULL, 65536); V_DrawPatchShadowed(j, i, &subscreen43, bgp[8], NULL, 65536); }
// // HI_drawCoopStats // // Draws the cooperative-mode statistics matrix. Nothing fancy. // static void HI_drawCoopStats(void) { int i, ypos; static int statstage; V_FontWriteTextShadowed(in_bigfont, HIS_KILLS, 95, 35, &subscreen43); V_FontWriteTextShadowed(in_bigfont, HIS_BONUS, 155, 35, &subscreen43); V_FontWriteTextShadowed(in_bigfont, HIS_SECRET, 232, 35, &subscreen43); HI_drawOldLevelName(3); ypos = 50; if(intertime < 40) statstage = 0; else if(intertime >= 40 && statstage == 0) { statstage = 1; S_StartInterfaceSound(sfx_hdorcls); } for(i = 0; i < MAXPLAYERS; ++i) { if(HI_playerInGame(i)) { V_DrawPatchShadowed(25, ypos, &subscreen43, PatchLoader::CacheNum(wGlobalDir, hi_faces[i], PU_CACHE), NULL, FRACUNIT); if(statstage == 1) { int kills = 0, items = 0, secrets = 0; if(hi_wbs.maxkills != 0) kills = hi_wbs.plyr[i].skills * 100 / hi_wbs.maxkills; if(hi_wbs.maxitems != 0) items = hi_wbs.plyr[i].sitems * 100 / hi_wbs.maxitems; if(hi_wbs.maxsecret != 0) secrets = hi_wbs.plyr[i].ssecret * 100 / hi_wbs.maxsecret; HI_drawLevelStatPct(kills, 85, ypos + 10, 121); HI_drawLevelStatPct(items, 160, ypos + 10, 196); HI_drawLevelStatPct(secrets, 237, ypos + 10, 273); } ypos += 37; } } }