Add all GetCortBoxColor calls back (also I found a vanilla bug)
This commit is contained in:
parent
5754da507d
commit
3eca2d7cf3
3 changed files with 30 additions and 4 deletions
|
@ -14,9 +14,13 @@
|
|||
|
||||
BACK gBack;
|
||||
int gWaterY;
|
||||
static unsigned long color_black;
|
||||
|
||||
BOOL InitBack(const char *fName, int type)
|
||||
{
|
||||
// Unused, hilariously
|
||||
color_black = GetCortBoxColor(RGB(0, 0, 0x10));
|
||||
|
||||
//Get width and height
|
||||
char path[PATH_LENGTH];
|
||||
sprintf(path, "%s/%s.pbm", gDataPath, fName);
|
||||
|
|
|
@ -267,6 +267,7 @@ int ModeTitle()
|
|||
int anime = 0;
|
||||
int char_type = 0;
|
||||
int time_counter = 0;
|
||||
unsigned long back_color = GetCortBoxColor(RGB(0x20, 0x20, 0x20));
|
||||
|
||||
//Set state
|
||||
bContinue = IsProfile();
|
||||
|
@ -356,7 +357,7 @@ int ModeTitle()
|
|||
anime = 0;
|
||||
|
||||
//Draw title
|
||||
CortBox(&grcGame, 0x202020);
|
||||
CortBox(&grcGame, back_color);
|
||||
|
||||
//Draw version
|
||||
PutBitmap3(&grcGame, (WINDOW_WIDTH - 120) / 2, WINDOW_HEIGHT - 24, &rcVersion, SURFACE_ID_TEXT_BOX);
|
||||
|
@ -443,7 +444,9 @@ int ModeAction()
|
|||
{
|
||||
int frame_x = 0;
|
||||
int frame_y = 0;
|
||||
|
||||
|
||||
unsigned long color = GetCortBoxColor(RGB(0, 0, 0x20));
|
||||
|
||||
bool swPlay = true;
|
||||
|
||||
//Reset stuff
|
||||
|
@ -525,7 +528,7 @@ int ModeAction()
|
|||
}
|
||||
|
||||
ProcFade();
|
||||
CortBox(&grcFull, 0x000020);
|
||||
CortBox(&grcFull, color);
|
||||
GetFramePosition(&frame_x, &frame_y);
|
||||
PutBack(frame_x, frame_y);
|
||||
PutStage_Back(frame_x, frame_y);
|
||||
|
|
|
@ -46,9 +46,17 @@ char text[0x100];
|
|||
|
||||
RECT gRect_line = {0, 0, 216, 16};
|
||||
|
||||
#ifdef FIX_BUGS
|
||||
static unsigned long nod_color;
|
||||
#endif
|
||||
|
||||
//Initialize and end tsc
|
||||
BOOL InitTextScript2()
|
||||
{
|
||||
#ifdef FIX_BUGS
|
||||
nod_color = GetCortBoxColor(RGB(0xFE, 0xFF, 0xFF));
|
||||
#endif
|
||||
|
||||
//Clear flags
|
||||
gTS.mode = 0;
|
||||
g_GameFlags &= ~0x04;
|
||||
|
@ -456,7 +464,18 @@ void PutTextScript()
|
|||
rect.top = gTS.ypos_line[gTS.line % 4] + gTS.rcText.top + gTS.offsetY;
|
||||
rect.right = rect.left + 5;
|
||||
rect.bottom = rect.top + 11;
|
||||
CortBox(&rect, 0xFFFFFE);
|
||||
#ifdef FIX_BUGS
|
||||
CortBox(&rect, nod_color);
|
||||
|
||||
// This is how the Linux port fixed this, but it isn't done
|
||||
// the way Pixel would do it (he only calls GetCortBoxColor
|
||||
// once, during init functions, so our fix does it that way
|
||||
// instead).
|
||||
// Also, the red/blue values are swapped for some reason.
|
||||
//CortBox(&rect, GetCortBoxColor(RGB(0xFF, 0xFF, 0xFE));
|
||||
#else
|
||||
CortBox(&rect, RGB(0xFE, 0xFF, 0xFF));
|
||||
#endif
|
||||
}
|
||||
|
||||
//Draw GIT
|
||||
|
|
Loading…
Add table
Reference in a new issue