Subversion Repositories eduke32

Rev

Rev 8447 | Rev 8488 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 8447 Rev 8478
Line 575... Line 575...
575
    Bsprintf(tempbuf, "There was a problem initializing the engine: %s\n", engineerrstr);
575
    Bsprintf(tempbuf, "There was a problem initializing the engine: %s\n", engineerrstr);
576
    ERRprintf("%s", tempbuf);
576
    ERRprintf("%s", tempbuf);
577
    fatal_exit(tempbuf);
577
    fatal_exit(tempbuf);
578
}
578
}
579
579
-
 
580
static void InitCustomColors()
-
 
581
{
-
 
582
    /* blue */
-
 
583
    vgapal16[9*4+0] = 252;
-
 
584
    vgapal16[9*4+1] = 124;
-
 
585
    vgapal16[9*4+2] = 28;
-
 
586
-
 
587
    /* orange */
-
 
588
    vgapal16[31*4+0] = 80; // blue
-
 
589
    vgapal16[31*4+1] = 180; // green
-
 
590
    vgapal16[31*4+2] = 240; // red
-
 
591
-
 
592
    // UNUSED?
-
 
593
    vgapal16[39*4+0] = 144;
-
 
594
    vgapal16[39*4+1] = 212;
-
 
595
    vgapal16[39*4+2] = 252;
-
 
596
-
 
597
-
 
598
    /* light yellow */
-
 
599
    vgapal16[22*4+0] = 204;
-
 
600
    vgapal16[22*4+1] = 252;
-
 
601
    vgapal16[22*4+2] = 252;
-
 
602
-
 
603
    /* grey */
-
 
604
    vgapal16[23*4+0] = 180;
-
 
605
    vgapal16[23*4+1] = 180;
-
 
606
    vgapal16[23*4+2] = 180;
-
 
607
-
 
608
    /* blue */
-
 
609
    vgapal16[24*4+0] = 204;
-
 
610
    vgapal16[24*4+1] = 164;
-
 
611
    vgapal16[24*4+2] = 48;
-
 
612
-
 
613
    vgapal16[32*4+0] = 240;
-
 
614
    vgapal16[32*4+1] = 200;
-
 
615
    vgapal16[32*4+2] = 84;
-
 
616
-
 
617
    // grid color
-
 
618
    vgapal16[25*4+0] = 64;
-
 
619
    vgapal16[25*4+1] = 56;
-
 
620
    vgapal16[25*4+2] = 56;
-
 
621
-
 
622
    vgapal16[26*4+0] = 96;
-
 
623
    vgapal16[26*4+1] = 96;
-
 
624
    vgapal16[26*4+2] = 96;
-
 
625
-
 
626
    // UNUSED?
-
 
627
    vgapal16[33*4+0] = 0; //60; // blue
-
 
628
    vgapal16[33*4+1] = 0; //120; // green
-
 
629
    vgapal16[33*4+2] = 192; //180; // red
-
 
630
-
 
631
    // UNUSED?
-
 
632
    vgapal16[41*4+0] = 0; //96;
-
 
633
    vgapal16[41*4+1] = 0; //160;
-
 
634
    vgapal16[41*4+2] = 252; //192;
-
 
635
-
 
636
    for (int i = 0; i<256; i++)
-
 
637
    {
-
 
638
        if (editorcolors[i] == 0)
-
 
639
        {
-
 
640
            palette_t *edcol = (palette_t *)&vgapal16[4*i];
-
 
641
            editorcolors[i] = getclosestcol_lim(edcol->b,edcol->g,edcol->r, 239);
-
 
642
        }
-
 
643
    }
-
 
644
}
-
 
645
580
int app_main(int argc, char const * const * argv)
646
int app_main(int argc, char const * const * argv)
581
{
647
{
582
#ifdef STARTUP_SETUP_WINDOW
648
#ifdef STARTUP_SETUP_WINDOW
583
    char cmdsetup = 0;
649
    char cmdsetup = 0;
584
#endif
650
#endif
Line 698... Line 764...
698
    g_defModules.clear();
764
    g_defModules.clear();
699
765
700
    if (enginePostInit())
766
    if (enginePostInit())
701
        M32_FatalEngineError();
767
        M32_FatalEngineError();
702
768
-
 
769
    InitCustomColors();
-
 
770
703
    CallExtPostInit();
771
    CallExtPostInit();
704
772
705
#ifdef YAX_ENABLE
773
#ifdef YAX_ENABLE
706
    // init dummy texture for YAX
774
    // init dummy texture for YAX
707
    // must be after loadpics(), which inits BUILD's cache
775
    // must be after loadpics(), which inits BUILD's cache