In Mapster32, remove ReadGamePalette() and GAMEpalette[] and use engine's palette[].

git-svn-id: https://svn.eduke32.com/eduke32@2515 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
helixhorned 2012-03-22 22:46:56 +00:00
parent 55dc8fee40
commit 3e1a8c523d
2 changed files with 5 additions and 23 deletions

View file

@ -3044,23 +3044,6 @@ static void ReadPaletteTable(void)
// initprintf("success.\n"); // initprintf("success.\n");
}// end ReadPaletteTable }// end ReadPaletteTable
static void ReadGamePalette(void)
{
int32_t fp;
if ((fp=kopen4load("palette.dat",0)) == -1)
if ((fp=kopen4load("palette.dat",1)) == -1)
{
initprintf("!!! PALETTE.DAT NOT FOUND !!!\n");
Bsprintf(tempbuf, "Mapster32 %s %s", VERSION, s_buildRev);
wm_msgbox(tempbuf,"palette.dat not found");
exit(0);
}
// initprintf("Loading game palette... ");
kread(fp,GAMEpalette,768);
kclose(fp);
// initprintf("success.\n");
ReadPaletteTable();
}
static void m32_showmouse(void) static void m32_showmouse(void)
{ {
@ -10463,8 +10446,7 @@ int32_t ExtInit(void)
showinvisibility = 1; showinvisibility = 1;
ReadGamePalette(); ReadPaletteTable();
// InitWater();
InitCustomColors(); InitCustomColors();
@ -11972,7 +11954,7 @@ void SetGAMEPalette(void)
{ {
if (acurpalette==0) return; if (acurpalette==0) return;
acurpalette=0; acurpalette=0;
setbrightness(GAMMA_CALC,6,2); setbrightness(GAMMA_CALC,0,2);
} }
static void SearchSectors(int32_t dir) // <0: backwards, >=0: forwards static void SearchSectors(int32_t dir) // <0: backwards, >=0: forwards

View file

@ -73,12 +73,12 @@ static void EditWallData(int16_t wallnum);
static void EditSectorData(int16_t sectnum); static void EditSectorData(int16_t sectnum);
static void FuncMenu(void); static void FuncMenu(void);
#define BASEPALCOUNT 7 #define BASEPALCOUNT 6
static uint8_t GAMEpalette[768], WATERpalette[768], SLIMEpalette[768], TITLEpalette[768]; static uint8_t WATERpalette[768], SLIMEpalette[768], TITLEpalette[768];
static uint8_t REALMSpalette[768], BOSS1palette[768]; static uint8_t REALMSpalette[768], BOSS1palette[768];
uint8_t *basepaltable[BASEPALCOUNT] = { palette, WATERpalette, SLIMEpalette, TITLEpalette, REALMSpalette, BOSS1palette, GAMEpalette }; static uint8_t *basepaltable[BASEPALCOUNT] = { palette, WATERpalette, SLIMEpalette, TITLEpalette, REALMSpalette, BOSS1palette };
static char num_tables; static char num_tables;