mirror of
https://github.com/Shpoike/Quakespasm.git
synced 2025-02-02 22:11:22 +00:00
Add QUAKESPASM_VER_SUFFIX macro for marking betas/dev builds.
Refactor printing of QUAKESPASM_VERSION/QUAKESPASM_VER_PATCH to use a new QUAKESPASM_VER_STRING macro. git-svn-id: svn://svn.code.sf.net/p/quakespasm/code/trunk/quakespasm@1408 af15c1b1-3010-417e-b628-4374ebc0bcbd
This commit is contained in:
parent
ebe31714b2
commit
e45de4c68a
6 changed files with 14 additions and 6 deletions
|
@ -1238,7 +1238,7 @@ void Con_DrawConsole (int lines, qboolean drawinput)
|
|||
|
||||
//draw version number in bottom right
|
||||
y += 8;
|
||||
sprintf (ver, "QuakeSpasm %1.2f.%d", (float)QUAKESPASM_VERSION, QUAKESPASM_VER_PATCH);
|
||||
sprintf (ver, "QuakeSpasm " QUAKESPASM_VER_STRING);
|
||||
for (x = 0; x < (int)strlen(ver); x++)
|
||||
Draw_Character ((con_linewidth - strlen(ver) + x + 2)<<3, y, ver[x] /*+ 128*/);
|
||||
}
|
||||
|
|
|
@ -569,7 +569,7 @@ static qboolean VID_SetMode (int width, int height, int bpp, qboolean fullscreen
|
|||
SDL_GL_SetAttribute(SDL_GL_MULTISAMPLEBUFFERS, fsaa > 0 ? 1 : 0);
|
||||
SDL_GL_SetAttribute(SDL_GL_MULTISAMPLESAMPLES, fsaa);
|
||||
|
||||
q_snprintf(caption, sizeof(caption), "QuakeSpasm %1.2f.%d", (float)QUAKESPASM_VERSION, QUAKESPASM_VER_PATCH);
|
||||
q_snprintf(caption, sizeof(caption), "QuakeSpasm " QUAKESPASM_VER_STRING);
|
||||
|
||||
#if defined(USE_SDL2)
|
||||
/* Create the window if needed, hidden */
|
||||
|
|
|
@ -220,7 +220,7 @@ void Host_FindMaxClients (void)
|
|||
void Host_Version_f (void)
|
||||
{
|
||||
Con_Printf ("Quake Version %1.2f\n", VERSION);
|
||||
Con_Printf ("QuakeSpasm Version %1.2f.%d\n", QUAKESPASM_VERSION, QUAKESPASM_VER_PATCH);
|
||||
Con_Printf ("QuakeSpasm Version " QUAKESPASM_VER_STRING "\n");
|
||||
Con_Printf ("Exe: " __TIME__ " " __DATE__ "\n");
|
||||
}
|
||||
|
||||
|
|
|
@ -133,8 +133,7 @@ int main(int argc, char *argv[])
|
|||
Sys_Printf("GLQuake %1.2f (c) id Software\n", GLQUAKE_VERSION);
|
||||
Sys_Printf("FitzQuake %1.2f (c) John Fitzgibbons\n", FITZQUAKE_VERSION);
|
||||
Sys_Printf("FitzQuake SDL port (c) SleepwalkR, Baker\n");
|
||||
Sys_Printf("QuakeSpasm %1.2f.%d (c) Ozkan Sezer, Eric Wasylishen & others\n",
|
||||
QUAKESPASM_VERSION, QUAKESPASM_VER_PATCH);
|
||||
Sys_Printf("QuakeSpasm " QUAKESPASM_VER_STRING " (c) Ozkan Sezer, Eric Wasylishen & others\n");
|
||||
|
||||
Sys_Printf("Host_Init\n");
|
||||
Host_Init();
|
||||
|
|
|
@ -1667,7 +1667,7 @@ void M_Quit_Draw (void) //johnfitz -- modified for new quit message
|
|||
m_state = m_quit;
|
||||
}
|
||||
|
||||
sprintf(msg1, "QuakeSpasm %1.2f.%d", (float)QUAKESPASM_VERSION, QUAKESPASM_VER_PATCH);
|
||||
sprintf(msg1, "QuakeSpasm " QUAKESPASM_VER_STRING);
|
||||
|
||||
//okay, this is kind of fucked up. M_DrawTextBox will always act as if
|
||||
//width is even. Also, the width and lines values are for the interior of the box,
|
||||
|
|
|
@ -38,6 +38,15 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|||
#define FITZQUAKE_VERSION 0.85 //johnfitz
|
||||
#define QUAKESPASM_VERSION 0.92
|
||||
#define QUAKESPASM_VER_PATCH 2 // helper to print a string like 0.92.1
|
||||
#ifndef QUAKESPASM_VER_SUFFIX
|
||||
#define QUAKESPASM_VER_SUFFIX // optional version suffix like -beta1
|
||||
#endif
|
||||
|
||||
#define QS_STRINGIFY2(x) QS_STRINGIFY(x)
|
||||
#define QS_STRINGIFY(x) #x
|
||||
|
||||
// combined version string like "0.92.1-beta1"
|
||||
#define QUAKESPASM_VER_STRING QS_STRINGIFY2(QUAKESPASM_VERSION) "." QS_STRINGIFY2(QUAKESPASM_VER_PATCH) QS_STRINGIFY2(QUAKESPASM_VER_SUFFIX)
|
||||
|
||||
//define PARANOID // speed sapping error checking
|
||||
|
||||
|
|
Loading…
Reference in a new issue