mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-02-04 04:40:56 +00:00
Progress towards KenBuild Editor, part 2.
DONT_BUILD. git-svn-id: https://svn.eduke32.com/eduke32@4560 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
5237346f5b
commit
16cd8b8aaa
7 changed files with 47 additions and 52 deletions
|
@ -53,10 +53,7 @@ extern int32_t __fastcall Gv_GetVarX(register int32_t id);
|
|||
extern void __fastcall Gv_SetVarX(register int32_t id, register int32_t lValue);
|
||||
extern int32_t __fastcall Gv_GetVarN(register int32_t id); // 'N' for "no side-effects"... vars and locals only!
|
||||
|
||||
extern void SetGAMEPalette(void);
|
||||
extern void SetWATERPalette(void);
|
||||
extern void SetSLIMEPalette(void);
|
||||
extern void SetBOSS1Palette(void);
|
||||
extern void SetGamePalette(int32_t);
|
||||
|
||||
extern int32_t *constants, constants_allocsize;
|
||||
extern int32_t g_numSavedConstants;
|
||||
|
|
|
@ -6089,15 +6089,15 @@ static void Keys3d(void)
|
|||
if (cursectnum>=0 && sector[cursectnum].lotag==2)
|
||||
{
|
||||
if (sector[cursectnum].ceilingpicnum==FLOORSLIME)
|
||||
SetSLIMEPalette();
|
||||
SetGamePalette(SLIMEPAL);
|
||||
else
|
||||
SetWATERPalette();
|
||||
SetGamePalette(WATERPAL);
|
||||
}
|
||||
else SetGAMEPalette();
|
||||
else SetGamePalette(BASEPAL);
|
||||
|
||||
if (keystatus[buildkeys[BK_MODE2D_3D]]) // Enter
|
||||
{
|
||||
SetGAMEPalette();
|
||||
SetGamePalette(BASEPAL);
|
||||
FX_StopAllSounds();
|
||||
S_ClearSoundLocks();
|
||||
|
||||
|
@ -11989,32 +11989,22 @@ void faketimerhandler(void)
|
|||
sampletimer();
|
||||
}
|
||||
|
||||
void SetBOSS1Palette(void)
|
||||
void SetGamePalette(int32_t j)
|
||||
{
|
||||
if (acurpalette==3) return;
|
||||
acurpalette=3;
|
||||
setbrightness(GAMMA_CALC,5,2);
|
||||
}
|
||||
|
||||
void SetSLIMEPalette(void)
|
||||
{
|
||||
if (acurpalette==2) return;
|
||||
acurpalette=2;
|
||||
setbrightness(GAMMA_CALC,2,2);
|
||||
}
|
||||
|
||||
void SetWATERPalette(void)
|
||||
{
|
||||
if (acurpalette==1) return;
|
||||
acurpalette=1;
|
||||
setbrightness(GAMMA_CALC,1,2);
|
||||
}
|
||||
|
||||
void SetGAMEPalette(void)
|
||||
{
|
||||
if (acurpalette==0) return;
|
||||
acurpalette=0;
|
||||
setbrightness(GAMMA_CALC,0,2);
|
||||
switch (j)
|
||||
{
|
||||
default:
|
||||
j=0;
|
||||
case 0:
|
||||
case 1:
|
||||
case 2:
|
||||
case 3:
|
||||
if (acurpalette==j)
|
||||
return;
|
||||
acurpalette=j;
|
||||
setbrightness(GAMMA_CALC,j,2);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
static void SearchSectors(int32_t dir) // <0: backwards, >=0: forwards
|
||||
|
|
|
@ -43,6 +43,17 @@ enum instpath_t {
|
|||
NUMINSTPATHS
|
||||
};
|
||||
|
||||
typedef enum basepal_ {
|
||||
BASEPAL = 0,
|
||||
WATERPAL,
|
||||
SLIMEPAL,
|
||||
DREALMSPAL,
|
||||
TITLEPAL,
|
||||
ENDINGPAL, // 5
|
||||
ANIMPAL,
|
||||
BASEPALCOUNT
|
||||
} basepal_t;
|
||||
|
||||
extern const char *g_gameNamePtr;
|
||||
|
||||
extern const char *defaultgamegrp[GAMECOUNT];
|
||||
|
|
|
@ -84,17 +84,6 @@ enum LogoFlags_t {
|
|||
LOGO_NODUKETEAMPIC = 0x00100000,
|
||||
};
|
||||
|
||||
typedef enum basepal_ {
|
||||
BASEPAL = 0,
|
||||
WATERPAL,
|
||||
SLIMEPAL,
|
||||
DREALMSPAL,
|
||||
TITLEPAL,
|
||||
ENDINGPAL, // 5
|
||||
ANIMPAL,
|
||||
BASEPALCOUNT
|
||||
} basepal_t;
|
||||
|
||||
enum ScreenTextFlags_t {
|
||||
TEXT_XRIGHT = 0x00000001,
|
||||
TEXT_XCENTER = 0x00000002,
|
||||
|
|
|
@ -2935,14 +2935,7 @@ dodefault:
|
|||
|
||||
case CON_SETGAMEPALETTE:
|
||||
insptr++;
|
||||
switch (Gv_GetVarX(*insptr++))
|
||||
{
|
||||
default:
|
||||
case 0: SetGAMEPalette(); break;
|
||||
case 1: SetWATERPalette(); break;
|
||||
case 2: SetSLIMEPalette(); break;
|
||||
case 3: SetBOSS1Palette(); break;
|
||||
}
|
||||
SetGamePalette(Gv_GetVarX(*insptr++));
|
||||
continue;
|
||||
|
||||
// *** sounds
|
||||
|
|
|
@ -20,6 +20,17 @@
|
|||
const char* AppProperName = "KenBuild Editor";
|
||||
const char* AppTechnicalName = "testeditor";
|
||||
|
||||
#if defined(_WIN32)
|
||||
#define DEFAULT_GAME_EXEC "testgame.exe"
|
||||
#define DEFAULT_GAME_LOCAL_EXEC "testgame.exe"
|
||||
#else
|
||||
#define DEFAULT_GAME_EXEC "eduke32"
|
||||
#define DEFAULT_GAME_LOCAL_EXEC "./eduke32"
|
||||
#endif
|
||||
|
||||
const char* DefaultGameExec = DEFAULT_GAME_EXEC;
|
||||
const char* DefaultGameLocalExec = DEFAULT_GAME_LOCAL_EXEC;
|
||||
|
||||
#define SETUPFILENAME "testeditor.cfg"
|
||||
const char *defaultsetupfilename = SETUPFILENAME;
|
||||
char setupfilename[BMAX_PATH] = SETUPFILENAME;
|
||||
|
|
|
@ -9,6 +9,10 @@ const char *G_DefaultDefFile(void)
|
|||
{
|
||||
return "kenbuild.def";
|
||||
}
|
||||
const char *G_DefFile(void)
|
||||
{
|
||||
return "kenbuild.def";
|
||||
}
|
||||
|
||||
uint8_t *basepaltable[1] = {
|
||||
palette
|
||||
|
|
Loading…
Reference in a new issue