From: havoc Date: Wed, 28 Nov 2007 06:46:25 +0000 (+0000) Subject: patch from VorteX which removes special menu behavior for X-Git-Tag: xonotic-v0.1.0preview~2758 X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fdarkplaces.git;a=commitdiff_plain;h=be511c50c3e4e5fa25e56fb957690072d51314c5 patch from VorteX which removes special menu behavior for GAME_NETHERWORLD, and replaces GAME_NETHERWORLD with GAME_DELUXEQUAKE git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@7726 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/common.c b/common.c index 42511e49..32a57efc 100644 --- a/common.c +++ b/common.c @@ -1163,9 +1163,9 @@ static const gamemode_info_t gamemode_info [] = // GAME_PRYDON // COMMANDLINEOPTION: Game: -prydon runs the topdown point and click action-RPG Prydon Gate { "prydon", "-prydon", "PrydonGate", "id1", "prydon", "prydon", "darkplaces" }, -// GAME_NETHERWORLD -// COMMANDLINEOPTION: Game: -netherworld runs the game Netherworld: Dark Master -{ "netherworld", "-netherworld", "Netherworld: Dark Master", "id1", "netherworld", "nw", "darkplaces" }, +// GAME_DELUXEQUAKE +// COMMANDLINEOPTION: Game: -dq runs the game Deluxe Quake +{ "dq", "-dq", "Deluxe Quake", "basedq", "extradq", "basedq", "dq" }, // GAME_THEHUNTED // COMMANDLINEOPTION: Game: -thehunted runs the game The Hunted { "thehunted", "-thehunted", "The Hunted", "thdata", NULL, "th", "thehunted" }, diff --git a/common.h b/common.h index c5bd0600..460d5325 100644 --- a/common.h +++ b/common.h @@ -270,7 +270,7 @@ typedef enum gamemode_e GAME_NEOTERIC, GAME_OPENQUARTZ, //this game sucks GAME_PRYDON, - GAME_NETHERWORLD, + GAME_DELUXEQUAKE, GAME_THEHUNTED, GAME_DEFEATINDETAIL2, GAME_DARSANA, diff --git a/image.c b/image.c index b41f7801..0745ea60 100644 --- a/image.c +++ b/image.c @@ -720,6 +720,20 @@ imageformat_t imageformats_nopath[] = {NULL, NULL} }; +// GAME_DELUXEQUAKE only +// VorteX: the point why i use such messy texture paths is +// that GtkRadiant can't detect normal/gloss textures +// and exclude them from texture browser +// so i just use additional folder to store this textures +imageformat_t imageformats_dq[] = +{ + {"%s.tga", LoadTGA}, + {"%s.jpg", JPEG_LoadImage}, + {"texturemaps/%s.tga", LoadTGA}, + {"texturemaps/%s.jpg", JPEG_LoadImage}, + {NULL, NULL} +}; + imageformat_t imageformats_textures[] = { {"%s.tga", LoadTGA_BGRA}, @@ -774,6 +788,8 @@ unsigned char *loadimagepixelsbgra (const char *filename, qboolean complain, qbo } if (gamemode == GAME_TENEBRAE) firstformat = imageformats_tenebrae; + else if (gamemode == GAME_DELUXEQUAKE) + firstformat = imageformats_dq; else if (!strcasecmp(name, "textures")) firstformat = imageformats_textures; else if (!strcasecmp(name, "gfx")) diff --git a/menu.c b/menu.c index 7bde1b9d..fd0d3a13 100644 --- a/menu.c +++ b/menu.c @@ -371,8 +371,6 @@ void M_Menu_Main_f (void) else MAIN_ITEMS = 6; } - else if (gamemode == GAME_NETHERWORLD)//VORTEX: menu restarting item - MAIN_ITEMS = 6; else if (gamemode == GAME_TRANSFUSION) { s = "gfx/menu/mainmenu1"; @@ -600,34 +598,6 @@ static void M_Main_Key (int key, char ascii) break; } } - else if (gamemode == GAME_NETHERWORLD)//VORTEX: menu restarting item - { - switch (m_main_cursor) - { - case 0: - M_Menu_SinglePlayer_f (); - break; - - case 1: - M_Menu_MultiPlayer_f (); - break; - - case 2: - M_Menu_Options_f (); - break; - - case 3: - M_Menu_Help_f (); - break; - - case 4: - M_Menu_Quit_f (); - break; - case 5: - MR_Restart(); - break; - } - } else if (gamemode == GAME_TRANSFUSION) { if (MAIN_ITEMS == 7) { @@ -5259,8 +5229,6 @@ void MR_Init_Commands(void) // set router console commands Cvar_RegisterVariable (&forceqmenu); Cvar_RegisterVariable (&menu_options_colorcontrol_correctionvalue); - if (gamemode == GAME_NETHERWORLD) - Cmd_AddCommand ("menu_fallback", MP_Fallback, "switch to engine menu (unload menu.dat)"); Cmd_AddCommand ("menu_restart",MR_Restart, "restart menu system (reloads menu.dat"); Cmd_AddCommand ("togglemenu", Call_MR_ToggleMenu_f, "opens or closes menu"); } diff --git a/sbar.c b/sbar.c index 21cdd6ca..5f53fb5d 100644 --- a/sbar.c +++ b/sbar.c @@ -146,7 +146,7 @@ void sbar_start(void) { int i; - if (gamemode == GAME_NETHERWORLD) + if (gamemode == GAME_DELUXEQUAKE) { } else if (gamemode == GAME_SOM) @@ -1151,7 +1151,7 @@ void Sbar_Draw (void) } else if (cl.intermission == 2) Sbar_FinaleOverlay(); - else if (gamemode == GAME_NETHERWORLD) + else if (gamemode == GAME_DELUXEQUAKE) { } else if (gamemode == GAME_SOM)