Merge branch 'mod-id-kill' into 'master'

Version number maintenance

See merge request KartKrew/Kart!2235
This commit is contained in:
James R. 2024-04-05 23:51:55 +00:00
commit 2fda2bc270
7 changed files with 15 additions and 23 deletions

View file

@ -2364,17 +2364,13 @@ static boolean CV_FilterVarByVersion(consvar_t *v, const char *valstr)
if (!(v->flags & CV_SAVE))
return true;
if (GETMAJOREXECVERSION(cv_execversion.value) < 2) // 2 = 1.0.2
#if 0 // We don't have changed saved cvars yet
if (GETMAJOREXECVERSION(cv_execversion.value) < 2)
{
#if 0
// We don't have changed saved cvars yet
if (!stricmp(v->name, "alwaysmlook")
|| !stricmp(v->name, "alwaysmlook2")
|| !stricmp(v->name, "mousemove")
|| !stricmp(v->name, "mousemove2"))
if (!stricmp(v->name, "example"))
return false;
#endif
}
#endif
return true;
}

View file

@ -5178,7 +5178,7 @@ static void Command_Version_f(void)
#ifdef UPDATE_ALERT
static void Command_ModDetails_f(void)
{
CONS_Printf(M_GetText("Mod ID: %d\nMod Version: %d\nCode Base:%d\n"), MODID, MODVERSION, CODEBASE);
CONS_Printf(M_GetText("Mod App Name: %s\nMod Version: %d\nCode Base:%d\n"), SRB2APPLICATION, MODVERSION, CODEBASE);
}
#endif

View file

@ -4479,7 +4479,6 @@ struct int_const_s const INT_CONST[] = {
{"MUSICRATE",MUSICRATE},
{"RING_DIST",RING_DIST},
{"PUSHACCEL",PUSHACCEL},
{"MODID",MODID}, // I don't know, I just thought it would be cool for a wad to potentially know what mod it was loaded into.
{"MODVERSION",MODVERSION}, // or what version of the mod this is.
{"CODEBASE",CODEBASE}, // or what release of SRB2 this is.
{"NEWTICRATE",NEWTICRATE}, // TICRATE*NEWTICRATERATIO

View file

@ -126,8 +126,8 @@ extern char logfilename[1024];
// the other options the same.
// Comment out this line to completely disable update alerts (recommended for testing, but not for release)
#ifndef BETAVERSION
//#define UPDATE_ALERT
#if !defined(BETAVERSION) && !defined(DEVELOP)
#define UPDATE_ALERT
#endif
// The string used in the alert that pops up in the event of an update being available.
@ -137,9 +137,7 @@ extern char logfilename[1024];
"Please visit kartkrew.org to download it.\n"\
"\n"\
"You are using version: %s\n"\
"The newest version is: %s\n"\
"\n"\
"(Press a key)\n"
"The newest version is: %s\n"
// For future use, the codebase is the version of SRB2 that the modification is based on,
// and should not be changed unless you have merged changes between versions of SRB2

View file

@ -336,6 +336,10 @@ int LUA_PushGlobals(lua_State *L, const char *word)
} else if (fastcmp(word,"VERSIONSTRING")) {
lua_pushstring(L, VERSIONSTRING);
return 1;
} else if (fastcmp(word,"APPLICATION")) {
// I don't know, I just thought it would be cool for a wad to potentially know what mod it was loaded into.
lua_pushstring(L, SRB2APPLICATION);
return 1;
} else if (fastcmp(word,"gamespeed")) {
lua_pushinteger(L, gamespeed);
return 1;

View file

@ -205,7 +205,7 @@ static void M_CheckMODVersion(int id)
#ifdef HAVE_THREADS
I_lock_mutex(&k_menu_mutex);
#endif
M_StartMessage("Game Update", updatestring, NULL, MM_NOTHING, NULL, NULL);
M_StartMessage("Game Update", updatestring, NULL, MM_NOTHING, NULL, "Return to Menu");
#ifdef HAVE_THREADS
I_unlock_mutex(k_menu_mutex);
#endif

View file

@ -1,15 +1,10 @@
#define SRB2VERSION "1.0"/* this must be the first line, for cmake !! */
// The Modification ID; must be obtained from a Master Server Admin ( https://mb.srb2.org/showgroups.php ).
// DO NOT try to set this otherwise, or your modification will be unplayable through the Master Server.
// "17" is the default mod ID for SRB2Kart.
#define MODID 17
#define SRB2VERSION "2.0"/* this must be the first line, for cmake !! */
// The Modification Version, starting from 1. Do not follow your version string for this,
// it's only for detection of the version the player is using so the MS can alert them of an update.
// Only set it higher, not lower, obviously.
// Note that we use this to help keep internal testing in check; this is why v2.0 is not version "2".
#define MODVERSION 6
#define MODVERSION 1
// Define this as a prerelease version suffix
// #define BETAVERSION "Alpha"