void DrawReview(char plr) { int clr, i, cte, P_value; char Fired_Flag = 0, Reset_Flag = 0; if (Data->P[plr].PresRev[0] != 0x7F) { FadeOut(2, display::graphics.palette(), 10, 0, 0); } PortPal(plr); display::graphics.screen()->clear(0); if (Data->P[plr].PresRev[0] == 0x7F) { Fired_Flag = 1; Data->P[plr].PresRev[0] = 16; } else if (Data->P[plr].PresRev[0] >= 16) { Reset_Flag = 1; Data->P[plr].PresRev[0] = 15; } ShBox(0, 0, 319, 22); ShBox(0, 24, 319, 199); draw_small_flag(plr, 4, 4); fill_rectangle(5, 28, 314, 195, 0); fill_rectangle(5, 122, 314, 195, 0); ShBox(6, 123, 313, 194); fill_rectangle(7, 124, 312, 193, 9); InBox(11, 128, 307, 189); fill_rectangle(12, 129, 306, 188, 7); ShBox(6, 29, 177, 121); ShBox(179, 29, 313, 121); InBox(182, 32, 309, 117); InBox(3, 3, 30, 19); IOBox(243, 3, 316, 19); if (plr == 0) { draw_heading(40, 5, "PRESIDENTIAL REVIEW", 0, -1); } else { draw_heading(40, 5, "POLITBURO REVIEW", 0, -1); } display::graphics.setForegroundColor(1); draw_string(257, 13, "CONTINUE"); display::graphics.setForegroundColor(1); draw_string(59, 36, "JOB PERFORMANCE"); display::graphics.setForegroundColor(6); draw_string(8, 46, "GOOD"); display::graphics.setForegroundColor(1); draw_string(8, 77, "FAIR"); display::graphics.setForegroundColor(9); draw_string(8, 109, "POOR"); display::graphics.setForegroundColor(1); draw_number(154, 117, Data->Year - 1); draw_number(126, 117, Data->Year - 2); draw_number(97, 117, Data->Year - 3); draw_number(70, 117, Data->Year - 4); draw_number(42, 117, Data->Year - 5); fill_rectangle(32, 39, 172, 111, 0); GradRect(33, 39, 171, 74, 0); GradRect(33, 75, 171, 110, 0); display::graphics.setForegroundColor(3); pline(60, 40, 60, 110); pline(88, 40, 88, 110); pline(116, 40, 116, 110); pline(144, 40, 144, 110); pline(33, 48, 171, 48); pline(33, 57, 171, 57); pline(33, 66, 171, 66); pline(33, 75, 171, 75); pline(33, 84, 171, 84); pline(33, 93, 171, 93); pline(33, 102, 171, 102); InBox(32, 39, 172, 111); for (i = 0; i < 5; i++) if (Data->P[plr].PresRev[i] > 16) { Data->P[plr].PresRev[i] = 16; } for (i = 0; i < 5; i++) { cte = 0; if (Data->P[plr].PresRev[i] < 8) { if (Data->P[plr].PresRev[i] == 7) { cte = 73; } else { cte = 40 + Data->P[plr].PresRev[i] * 5; } } else if (Data->P[plr].PresRev[i] > 8) { if (Data->P[plr].PresRev[i] == 9) { cte = 77; } else { cte = 80 + (Data->P[plr].PresRev[i] - 10) * 5; } }; if (Data->P[plr].PresRev[i] == 8) { cte = 73; } fill_rectangle(166 - i * 28, 75, 151 - i * 28, cte, 5 + ((Data->P[plr].PresRev[i] <= 8) ? 0 : 3)); display::graphics.setForegroundColor(6 + ((Data->P[plr].PresRev[i] <= 8) ? 0 : 3)); pline(167 - i * 28, 75, 167 - i * 28, cte); } if (Fired_Flag == 1) { clr = 0; for (i = 0; i < Data->P[plr].AstroCount; i++) if (Data->P[plr].Pool[i].Status == AST_ST_DEAD) { clr++; } Data->P[plr].PresRev[0] = (clr >= 2) ? 17 : 16; } DrawRevText(plr, Data->P[plr].PresRev[0]); if (Data->P[plr].PresRev[0] == 17) { Data->P[plr].PresRev[0] = 16; } P_value = 0; // 0 pres. 1 v.p. if (plr == 0) { if (Data->P[plr].PresRev[0] <= 4 || Data->P[plr].PresRev[0] >= 11) { P_value = 0; } else { P_value = 1; } }; if (plr == 1) { if (Data->P[plr].PresRev[0] <= 4 || Data->P[plr].PresRev[0] >= 12) { P_value = 0; } else { P_value = 1; } } if (plr == 0) { if (Data->Year <= 60) { if (P_value == 0) { PresPict(0); } else { PresPict(1); } } else if (Data->Year >= 61 && Data->Year <= 63) { if (P_value == 0) { PresPict(2); } else { PresPict(3); } } else if (Data->Year >= 64 && Data->Year <= 68) { if (P_value == 0) { PresPict(4); } else { PresPict(5); } } else if (Data->Year >= 69 && Data->Year <= 73) { if (P_value == 0) { PresPict(6); } else { PresPict(7); } } else if (Data->Year >= 74 && Data->Year <= 76) { if (P_value == 0) { PresPict(8); } else { PresPict(9); } } else if (Data->Year >= 77) { if (P_value == 0) { PresPict(10); } else { PresPict(11); } } } if (plr == 1) { if (Data->Year < 61) { if (P_value == 0) { PresPict(14); } else { PresPict(15); } } else if (Data->Year <= 64) { if (P_value == 0) { PresPict(12); } else { PresPict(13); } } else if (Data->Year >= 65) { if (P_value == 0) { PresPict(16); } else { PresPict(17); } } } if (Reset_Flag == 1) { Data->P[plr].PresRev[0] = 16; } FadeIn(2, display::graphics.palette(), 10, 0, 0); return; }
void ShowPrest(char plr) { char pos = -1, pos2 = -1; int i, j; for (j = 0; j < 2; j++) for (i = 0; i < 28; i++) { TPoints[j] += (int) Data->Prestige[i].Points[j]; } FadeOut(2, display::graphics.palette(), 5, 0, 0); PortPal(plr); display::graphics.screen()->clear(0); ShBox(0, 0, 319, 22); ShBox(0, 24, 319, 199); InBox(4, 27, 315, 196); fill_rectangle(5, 28, 314, 195, 0); //ShBox(6,29,125,101); ShBox(6, 29, 56, 101); InBox(17, 46, 44, 62); InBox(70, 42, 174, 92); ShBox(179, 29, 313, 101); ShBox(58, 29, 313, 101); InBox(70, 42, 174, 92); InBox(185, 42, 304, 92); //ShBox(136,74,163,90); IOBox(243, 3, 316, 19); ShBox(6, 104, 313, 194); InBox(10, 127, 309, 191); fill_rectangle(11, 128, 308, 190, 0); ShBox(297, 129, 307, 158); ShBox(297, 160, 307, 189); // Arrows draw_heading(8, 5, "PRESTIGE SUMMARY", 0, -1); draw_heading(14, 109, "EVENTS", 0, -1); display::graphics.setForegroundColor(11); draw_string(140, 120, "1ST:"); draw_string(175, 120, "2ND:"); draw_string(212, 120, "SUBS:"); draw_string(254, 120, "FAIL:"); display::graphics.setForegroundColor(1); draw_string(257, 13, "CONTINUE"); draw_string(17, 39, "FIRST:"); draw_string(19, 81, "DATE:"); display::graphics.setForegroundColor(11); draw_string(71, 37, "# SPACE FIRSTS:"); draw_string(187, 37, "TOTAL POINTS:"); display::graphics.setForegroundColor(1); display::graphics.setForegroundColor(6); draw_string(210, 99, "USA"); draw_string(90, 99, "USA"); display::graphics.setForegroundColor(9); draw_string(261, 99, "USSR"); draw_string(135, 99, "USSR"); draw_up_arrow(299, 131); draw_down_arrow(299, 162); DPrest(plr, &pos, &pos2); FadeIn(2, display::graphics.palette(), 5, 0, 0); WaitForMouseUp(); while (1) { GetMouse(); // Parse Button actions, note that return is embedded in first pButton if ((x >= 245 && y >= 5 && x <= 314 && y <= 17 && mousebuttons > 0) || key == K_ENTER) { InBox(245, 5, 314, 17); if (key > 0) { delay(300); key = 0; }; WaitForMouseUp(); OutBox(245, 5, 314, 17); key = 0; helpText = "i000"; keyHelpText = "k000"; return; } pButton(297, 129, 307, 158, BackOne(plr, &pos, &pos2), key >> 8, 72); pButton(297, 160, 307, 189, ForOne(plr, &pos, &pos2), key >> 8, 80); Button2(15, 129, 160, 133, Move2(plr, &pos, &pos2, 0), key, 49); Button2(15, 136, 160, 140, Move2(plr, &pos, &pos2, 1), key, 50); Button2(15, 143, 160, 147, Move2(plr, &pos, &pos2, 2), key, 51); Button2(15, 150, 160, 154, Move2(plr, &pos, &pos2, 3), key, 52); Button2(15, 157, 160, 161, Move2(plr, &pos, &pos2, 4), key, 53); Button2(15, 164, 160, 168, Move2(plr, &pos, &pos2, 5), key, 54); Button2(15, 171, 160, 175, Move2(plr, &pos, &pos2, 6), key, 55); Button2(15, 178, 160, 182, Move2(plr, &pos, &pos2, 7), key, 56); Button2(15, 185, 160, 189, Move2(plr, &pos, &pos2, 8), key, 57); key = 0; }; }
void MisAnn(char plr, char pad) { int i, j, bud; struct mStr Mis2; char k, hold, Digit[4], HelpFlag = 0; char pad_str[2] = {'A' + pad, '\0'}; for (i = 0; i < 768; i++) { pal[i] = 0; } gxClearDisplay(0, 0); PortPal(plr); ShBox(41, 20, 281, 184); InBox(46, 25, 276, 179); InBox(46, 25, 117, 65); Flag(47, 26, plr); InBox(122, 25, 276, 65); grSetColor(9); PrintAt(127, 33, "SCHEDULED LAUNCH"); //was 154,33 grSetColor(34); PrintAt(127, 40, "LAUNCH FACILITY: "); grSetColor(1); PrintAt(0, 0, "PAD "); PrintAt(0, 0, pad_str); grSetColor(34); PrintAt(127, 47, "DATE: "); grSetColor(1); PrintAt(0, 0, Month[Data->P[plr].Mission[pad].Month]); PrintAt(0, 0, "19"); DispNum(0, 0, Data->Year); grSetColor(1); GetMisType(Data->P[plr].Mission[pad].MissionCode); memcpy(&Mis2, &Mis, sizeof Mis); if ((Mis.mVab[0] & 0x10) == 0x10 && Data->P[plr].DMod <= 0) { i = 0; while (dg[Mis2.Index][i] != 0 && Mis.Doc == 1) { GetMisType(dg[Mis2.Index][i]); i++; } if (dg[Mis2.Index][i] == 0) { Data->P[plr].Mission[pad].MissionCode = 4; // new mission } else { Data->P[plr].Mission[pad].MissionCode = Mis.Index; // new mission } GetMisType(Data->P[plr].Mission[pad].MissionCode); HelpFlag = 1; } PrintAt(127, 54, Mis.Abbr); int MisCod; MisCod = Data->P[plr].Mission[pad].MissionCode; if ((MisCod > 24 && MisCod < 32) || MisCod == 33 || MisCod == 34 || MisCod == 35 || MisCod == 37 || MisCod == 40 || MisCod == 41) // Show duration level only on missions with a Duration step - Leon { switch (Data->P[plr].Mission[pad].Duration) { case 1: PrintAt(0, 0, ""); break; case 2: PrintAt(0, 0, " (B)"); break; case 3: PrintAt(0, 0, " (C)"); break; case 4: PrintAt(0, 0, " (D)"); break; case 5: PrintAt(0, 0, " (E)"); break; case 6: PrintAt(0, 0, " (F)"); break; default: PrintAt(0, 0, ""); break; } } IOBox(57, 68, 118, 84); IOBox(131, 68, 197, 84); IOBox(205, 68, 266, 84); grSetColor(1); PrintAt(65, 78, "CONTINUE"); PrintAt(139, 78, "PLAY FULL"); PrintAt(221, 78, "SCRUB"); grSetColor(9); MisCod = Data->P[plr].Mission[i].MissionCode; PrintAt(65, 78, "C"); PrintAt(139, 78, "P"); PrintAt(221, 78, "S"); //IOBox(85,68,158,84);IOBox(172,68,245,84); //grSetColor(1);PrintAt(102,78,"CONTINUE");PrintAt(189,78,"SCRUB"); //grSetColor(9); //PrintAt(102,78,"C");PrintAt(189,78,"S"); if (Data->P[plr].Mission[pad].Joint == 0) { PrintAt(128, 91, "SINGLE LAUNCH"); } else { PrintAt(131, 91, "JOINT LAUNCH"); PrintAt(49, 101, "PART ONE"); PrintAt(102, 101, "PAD "); //DispNum(0,0,pad); switch (pad) { case 0: PrintAt(0, 0, "A"); break; case 1: PrintAt(0, 0, "B"); break; case 2: PrintAt(0, 0, "C"); break; }; PrintAt(160, 101, "PART TWO"); PrintAt(213, 101, "PAD "); //DispNum(0,0,pad+1); switch (pad + 1) { case 0: PrintAt(0, 0, "A"); break; case 1: PrintAt(0, 0, "B"); break; case 2: PrintAt(0, 0, "C"); break; }; } for (i = 0; i < Data->P[plr].Mission[pad].Joint + 1; i++) { k = 0; if (i == 0) { bud = 49; } else { bud = 160; } for (j = Mission_Capsule; j <= Mission_PrimaryBooster; j++) { hold = Data->P[plr].Mission[pad + i].Hard[j]; switch (j) { case 0: if (hold > -1) { grSetColor(7); PrintAt(bud, 109 + 14 * k, "CAPSULE: "); grSetColor(1); PrintAt(0, 0, &Data->P[plr].Manned[hold].Name[0]); grSetColor(11); PrintAt(bud, 116 + 14 * k, "SAFETY FACTOR: "); Data->P[plr].Manned[hold].Damage != 0 ? grSetColor(9) : grSetColor(1); //Damaged Equipment, Nikakd, 10/8/10 sprintf(&Digit[0], "%d", Data->P[plr].Manned[hold].Safety + Data->P[plr].Manned[hold].Damage); PrintAt(0, 0, &Digit[0]); PrintAt(0, 0, "%"); // PrintAt(144+i*111,116+14*k,"%"); ++k; }; break; case 1: if (hold > -1) { grSetColor(7); PrintAt(bud, 109 + 14 * k, "KICKER: "); grSetColor(1); PrintAt(0, 0, &Data->P[plr].Misc[hold].Name[0]); grSetColor(11); PrintAt(bud, 116 + 14 * k, "SAFETY FACTOR: "); Data->P[plr].Misc[hold].Damage != 0 ? grSetColor(9) : grSetColor(1); //Damaged Equipment, Nikakd, 10/8/10 sprintf(&Digit[0], "%d", Data->P[plr].Misc[hold].Safety + Data->P[plr].Misc[hold].Damage); PrintAt(0, 0, &Digit[0]); PrintAt(0, 0, "%"); // DispNum(0,0,Data->P[plr].Misc[hold].Safety); // PrintAt(144+i*111,116+14*k,"%"); ++k; }; break; case 2: if (hold > -1) { grSetColor(7); PrintAt(bud, 109 + 14 * k, "LM: "); grSetColor(1); PrintAt(0, 0, &Data->P[plr].Manned[hold].Name[0]); grSetColor(11); PrintAt(bud, 116 + 14 * k, "SAFETY FACTOR: "); Data->P[plr].Manned[hold].Damage != 0 ? grSetColor(9) : grSetColor(1); //Damaged Equipment, Nikakd, 10/8/10 sprintf(&Digit[0], "%d", Data->P[plr].Manned[hold].Safety + Data->P[plr].Manned[hold].Damage); PrintAt(0, 0, &Digit[0]); PrintAt(0, 0, "%"); //DispNum(0,0,Data->P[plr].Manned[hold].Safety); //PrintAt(144+i*111,116+14*k,"%"); ++k; }; break; case 3: if (hold > -1) { if (hold < 3) { grSetColor(7); PrintAt(bud, 109 + 14 * k, "PROBE: "); grSetColor(1); PrintAt(0, 0, &Data->P[plr].Probe[hold].Name[0]); grSetColor(11); PrintAt(bud, 116 + 14 * k, "SAFETY FACTOR: "); Data->P[plr].Probe[hold].Damage != 0 ? grSetColor(9) : grSetColor(1); //Damaged Equipment, Nikakd, 10/8/10 sprintf(&Digit[0], "%d", Data->P[plr].Probe[hold].Safety + Data->P[plr].Probe[hold].Damage); PrintAt(0, 0, &Digit[0]); PrintAt(0, 0, "%"); //DispNum(0,0,Data->P[plr].Probe[hold].Safety); //PrintAt(144+i*111,116+14*k,"%"); ++k; } else if (hold == 4) { grSetColor(7); PrintAt(bud, 109 + 14 * k, "DOCKING: "); grSetColor(1); PrintAt(0, 0, &Data->P[plr].Misc[hold].Name[0]); grSetColor(11); PrintAt(bud, 116 + 14 * k, "SAFETY FACTOR: "); Data->P[plr].Misc[hold].Damage != 0 ? grSetColor(9) : grSetColor(1); //Damaged Equipment, Nikakd, 10/8/10 sprintf(&Digit[0], "%d", Data->P[plr].Misc[hold].Safety + Data->P[plr].Misc[hold].Damage); PrintAt(0, 0, &Digit[0]); PrintAt(0, 0, "%"); //DispNum(0,0,Data->P[plr].Misc[hold].Safety); //PrintAt(144+i*111,116+14*k,"%"); ++k; } }; break; case 4: if (hold > -1) { if (hold < 5) { grSetColor(7); PrintAt(bud, 109 + 14 * k, "ROCKET: "); grSetColor(1); PrintAt(0, 0, &Data->P[plr].Rocket[hold - 1].Name[0]); grSetColor(11); PrintAt(bud, 116 + 14 * k, "SAFETY FACTOR: "); Data->P[plr].Rocket[hold - 1].Damage != 0 ? grSetColor(9) : grSetColor(1); //Damaged Equipment, Nikakd, 10/8/10 sprintf(&Digit[0], "%d", Data->P[plr].Rocket[hold - 1].Safety + Data->P[plr].Rocket[hold - 1].Damage); PrintAt(0, 0, &Digit[0]); PrintAt(0, 0, "%"); //DispNum(0,0,Data->P[plr].Rocket[hold-1].Safety); //PrintAt(144+i*111,116+14*k,"%"); ++k; } else { grSetColor(7); PrintAt(bud, 109 + 14 * k, "ROCKET: "); grSetColor(1); PrintAt(0, 0, &Data->P[plr].Rocket[hold - 5].Name[0]); PrintAt(0, 0, " W/B"); grSetColor(11); PrintAt(bud, 116 + 14 * k, "SAFETY FACTOR: "); (Data->P[plr].Rocket[hold - 5].Damage != 0 || Data->P[plr].Rocket[4].Damage != 0) ? grSetColor(9) : grSetColor(1); //Damaged Equipment && Booster's Safety Mod, Nikakd, 10/8/10 sprintf(&Digit[0], "%d", RocketBoosterSafety(Data->P[plr].Rocket[hold - 5].Safety + Data->P[plr].Rocket[hold - 5].Damage, Data->P[plr].Rocket[4].Safety + Data->P[plr].Rocket[4].Damage)); PrintAt(0, 0, &Digit[0]); PrintAt(0, 0, "%"); // DispNum(0,0,(Data->P[plr].Rocket[hold-5].Safety+Data->P[plr].Rocket[4].Safety)/2); // PrintAt(144+i*111,116+14*k,"%"); ++k; } } break; default: break; } } } FadeIn(2, pal, 10, 0, 0); WaitForMouseUp(); if (HelpFlag) { Help("i156"); // Notification of being an Help } while (1) { key = 0; GetMouse(); if ((x >= 59 && y >= 70 && x <= 116 && y <= 82 && mousebuttons > 0) || key == K_ENTER || key == 'C') { InBox(59, 70, 116, 82); WaitForMouseUp(); OutBox(59, 70, 116, 82); FadeOut(2, pal, 10, 0, 0); BIG = 0; return; } else if ((x >= 133 && y >= 70 && x <= 195 && y <= 82 && mousebuttons > 0) || key == K_ENTER || key == 'P') { InBox(133, 70, 195, 82); WaitForMouseUp(); OutBox(133, 70, 195, 82); FadeOut(2, pal, 10, 0, 0); BIG = 1; return; } else if ((x >= 207 && y >= 70 && x <= 264 && y <= 82 && mousebuttons > 0) || key == 'S') { InBox(207, 70, 264, 82); WaitForMouseUp(); OutBox(207, 70, 264, 82); { ClrMiss(plr, pad); } if (Data->P[plr].Mission[pad].MissionCode == 0) { FadeOut(2, pal, 10, 0, 0); return; } } }; }
void Museum(char plr) { int i, tots = 7, beg; char AName[7][22] = {"DIRECTOR RANKING", "SPACE HISTORY", "MISSION RECORDS", "PRESTIGE SUMMARY", "HARDWARE EFFICIENCY", "ASTRONAUT HISTORY", "EXIT THE MUSEUM" }; char AImg[7] = {8, 9, 10, 11, 13, 14, 0}; if (Data->P[plr].AstroCount == 0) { memcpy(&AName[5][0], &AName[6][0], 22); // move up Exit AImg[5] = AImg[6]; tots = 6; } else if (plr == 1) { strncpy(&AName[5][0], "COSMO", 5); } AImg[3] += plr; // FadeOut(2,pal,10,0,0); music_start(M_THEME); beg = 0; do { if (beg == 0) { beg = (Data->P[plr].AstroCount > 0) ? 7 : 6; // mods for astros } else { FadeOut(2, display::graphics.palette(), 10, 0, 0); DrawSpaceport(plr); PortPal(plr); fill_rectangle(166, 191, 318, 198, 3); display::graphics.setForegroundColor(0); draw_string(257, 197, "CASH:"); draw_megabucks(285, 197, Data->P[plr].Cash); display::graphics.setForegroundColor(11); draw_string(256, 196, "CASH:"); draw_megabucks(284, 196, Data->P[plr].Cash); display::graphics.setForegroundColor(0); if (Data->Season == 0) { draw_string(166, 197, "SPRING 19"); } else { draw_string(166, 197, "FALL 19"); } draw_number(0, 0, Data->Year); display::graphics.setForegroundColor(11); if (Data->Season == 0) { draw_string(165, 196, "SPRING 19"); } else { draw_string(165, 196, "FALL 19"); } draw_number(0, 0, Data->Year); FadeIn(2, display::graphics.palette(), 10, 0, 0); } helpText = (plr == 0) ? "i700" : "i701"; keyHelpText = (plr == 0) ? "k603" : "k604"; i = BChoice(plr, tots, &AName[0][0], &AImg[0]); switch (i) { case 1: RankMe(plr); break; case 2: helpText = "i130"; keyHelpText = "k031"; ShowSpHist(plr); break; case 3: helpText = "i131"; keyHelpText = "k321"; Records(plr); break; case 4: helpText = "i132"; keyHelpText = "k033"; ShowPrest(plr); break; case 5: helpText = "i034"; ShowHard(plr); break; case 6: helpText = (plr == 0) ? "i133" : "i134"; keyHelpText = (plr == 0) ? "k035" : "k441"; if (Data->P[plr].AstroCount > 0) { ShowAstrosHist(plr); } break; case 7: default: break; } helpText = "i000"; keyHelpText = "k000"; } while (i != beg); music_stop(); return; }
void DrawStatistics(char Win) { GXHEADER local; char AImg[7] = {8, 9, 10, 11, 13, 14, 0}; char Digit[2]; int starty, qty, i; FILE *fin; strncpy(helptextIndex, "i145", 4); strncpy(keyhelpIndex, "k045", 4); FadeOut(2, pal, 10, 0, 0); PortPal(0); gxClearDisplay(0, 0); ShBox(35, 33, 288, 159); InBox(40, 69, 111, 109); InBox(116, 69, 283, 109); InBox(40, 114, 111, 154); InBox(116, 114, 283, 154); IOBox(191, 40, 280, 62); Flag(41, 70, Win); Flag(41, 115, other(Win)); DispBig(48, 44, "STATISTICS", 1, -1); DispBig(215, 45, "EXIT", 1, -1); grSetColor(6); PrintAt(122, 78, "WINNING DIRECTOR: "); grSetColor(8); if (AI[Win]) { PrintAt(0, 0, "COMPUTER"); sprintf(&Digit[0], "%d", Data->P[Win].Track[3]); PrintAt(0, 0, &Digit[0]); } else if (Win == 0) { PrintAt(0, 0, &Data->P[Data->Def.Plr1].Name[0]); } else { PrintAt(0, 0, &Data->P[ Data->Def.Plr2 ].Name[0]); } grSetColor(6); PrintAt(122, 125, "LOSING DIRECTOR: "); grSetColor(8); if (AI[other(Win)]) { PrintAt(0, 0, "COMPUTER"); sprintf(&Digit[0], "%d", Data->P[other(Win)].Track[3]); PrintAt(0, 0, &Digit[0]); } else if (Win == 0) { PrintAt(0, 0, &Data->P[Data->Def.Plr2].Name[0]); } else { PrintAt(0, 0, &Data->P[ Data->Def.Plr1 ].Name[0]); } qty = 6; starty = 118; GV(&local, 30, 19); fin = sOpen("PORTBUT.BUT", "rb", 0); OutBox(152, 41, 183, 61); //directors ranking for (i = 0; i < qty; i++) { if (i <= 4 && AI[Win] == 0) { OutBox(starty + (i * 33), 87, 31 + starty + (i * 33), 107); } if (i <= 4 && AI[other(Win)] == 0) { OutBox(starty + (i * 33), 132, 31 + starty + (i * 33), 152); } fseek(fin, AImg[i] * 570, SEEK_SET); fread((char *)local.vptr, 570, 1, fin); if (i == 0) { gxPutImage(&local, gxSET, 153, 42, 0); } else { if (AI[Win] == 0) { gxPutImage(&local, gxSET, starty + ((i - 1) * 33) + 1, 88, 0); } if (AI[other(Win)] == 0) { gxPutImage(&local, gxSET, starty + ((i - 1) * 33) + 1, 133, 0); } } } fclose(fin); DV(&local); FadeIn(2, pal, 10, 0, 0); return; }