mirror of
https://github.com/dhewm/dhewm3.git
synced 2025-03-20 09:41:13 +00:00
Get rid of ID_DEMO_BUILD
There are no demo pk4s compatible to this 1.3.1 codebase.
This commit is contained in:
parent
e2ca3d1f84
commit
3256783af1
18 changed files with 14 additions and 152 deletions
|
@ -14,7 +14,6 @@ cmake_minimum_required(VERSION 2.6)
|
|||
# SDK -D_D3SDK
|
||||
|
||||
# don't add these as options, but document them?
|
||||
# TARGET_DEMO there are no demo pk4s compatible to this 1.3.1 codebase
|
||||
# IDNET_HOST -DIDNET_HOST=\\"%s\\"' % IDNET_HOST
|
||||
# DEBUG_MEMORY -DID_DEBUG_MEMORY', '-DID_REDIRECT_NEWDELETE
|
||||
# LIBC_MALLOC -DUSE_LIBC_MALLOC=0
|
||||
|
|
|
@ -3425,7 +3425,6 @@ bool idGameLocal::InhibitEntitySpawn( idDict &spawnArgs ) {
|
|||
|
||||
|
||||
const char *name;
|
||||
#ifndef ID_DEMO_BUILD
|
||||
if ( g_skill.GetInteger() == 3 ) {
|
||||
name = spawnArgs.GetString( "classname" );
|
||||
// _D3XP :: remove moveable medkit packs also
|
||||
|
@ -3435,7 +3434,6 @@ bool idGameLocal::InhibitEntitySpawn( idDict &spawnArgs ) {
|
|||
result = true;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
if ( gameLocal.isMultiplayer ) {
|
||||
name = spawnArgs.GetString( "classname" );
|
||||
|
|
|
@ -454,15 +454,11 @@ void idInventory::RestoreInventory( idPlayer *owner, const idDict &dict ) {
|
|||
// weapons are stored as a number for persistant data, but as strings in the entityDef
|
||||
weapons = dict.GetInt( "weapon_bits", "0" );
|
||||
|
||||
#ifdef ID_DEMO_BUILD
|
||||
Give( owner, dict, "weapon", dict.GetString( "weapon" ), NULL, false );
|
||||
#else
|
||||
if ( g_skill.GetInteger() >= 3 ) {
|
||||
Give( owner, dict, "weapon", dict.GetString( "weapon_nightmare" ), NULL, false );
|
||||
} else {
|
||||
Give( owner, dict, "weapon", dict.GetString( "weapon" ), NULL, false );
|
||||
}
|
||||
#endif
|
||||
|
||||
num = dict.GetInt( "levelTriggers" );
|
||||
for ( i = 0; i < num; i++ ) {
|
||||
|
@ -1923,12 +1919,11 @@ void idPlayer::Spawn( void ) {
|
|||
g_damageScale.SetFloat( 1.0f );
|
||||
#endif
|
||||
g_armorProtection.SetFloat( ( g_skill.GetInteger() < 2 ) ? 0.4f : 0.2f );
|
||||
#ifndef ID_DEMO_BUILD
|
||||
|
||||
if ( g_skill.GetInteger() == 3 ) {
|
||||
healthTake = true;
|
||||
nextHealthTake = gameLocal.time + g_healthTakeTime.GetInteger() * 1000;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3985,7 +3980,7 @@ void idPlayer::UpdatePowerUps( void ) {
|
|||
nextHealthPulse = gameLocal.time + HEALTHPULSE_TIME;
|
||||
healthPulse = true;
|
||||
}
|
||||
#ifndef ID_DEMO_BUILD
|
||||
|
||||
if ( !gameLocal.inCinematic && influenceActive == 0 && g_skill.GetInteger() == 3 && gameLocal.time > nextHealthTake && !AI_DEAD && health > g_healthTakeLimit.GetInteger() ) {
|
||||
assert( !gameLocal.isClient ); // healthPool never be set on client
|
||||
|
||||
|
@ -4002,7 +3997,6 @@ void idPlayer::UpdatePowerUps( void ) {
|
|||
nextHealthTake = gameLocal.time + g_healthTakeTime.GetInteger() * 1000;
|
||||
healthTake = true;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
@ -196,19 +196,12 @@ idTarget_EndLevel::Event_Activate
|
|||
void idTarget_EndLevel::Event_Activate( idEntity *activator ) {
|
||||
idStr nextMap;
|
||||
|
||||
#ifdef ID_DEMO_BUILD
|
||||
if ( spawnArgs.GetBool( "endOfGame" ) ) {
|
||||
cvarSystem->SetCVarBool( "g_nightmare", true );
|
||||
gameLocal.sessionCommand = "endofDemo";
|
||||
return;
|
||||
}
|
||||
#else
|
||||
if ( spawnArgs.GetBool( "endOfGame" ) ) {
|
||||
cvarSystem->SetCVarBool( "g_nightmare", true );
|
||||
gameLocal.sessionCommand = "disconnect";
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
if ( !spawnArgs.GetString( "nextMap", "", nextMap ) ) {
|
||||
gameLocal.Printf( "idTarget_SessionCommand::Event_Activate: no nextMap key\n" );
|
||||
return;
|
||||
|
|
|
@ -2481,7 +2481,6 @@ void idGameLocal::InitConsoleCommands( void ) {
|
|||
cmdSystem->AddCommand( "clearLights", Cmd_ClearLights_f, CMD_FL_GAME|CMD_FL_CHEAT, "clears all lights" );
|
||||
cmdSystem->AddCommand( "gameError", Cmd_GameError_f, CMD_FL_GAME|CMD_FL_CHEAT, "causes a game error" );
|
||||
|
||||
#ifndef ID_DEMO_BUILD
|
||||
cmdSystem->AddCommand( "disasmScript", Cmd_DisasmScript_f, CMD_FL_GAME|CMD_FL_CHEAT, "disassembles script" );
|
||||
cmdSystem->AddCommand( "recordViewNotes", Cmd_RecordViewNotes_f, CMD_FL_GAME|CMD_FL_CHEAT, "record the current view position with notes" );
|
||||
cmdSystem->AddCommand( "showViewNotes", Cmd_ShowViewNotes_f, CMD_FL_GAME|CMD_FL_CHEAT, "show any view notes for the current map, successive calls will cycle to the next note" );
|
||||
|
@ -2501,7 +2500,6 @@ void idGameLocal::InitConsoleCommands( void ) {
|
|||
cmdSystem->AddCommand( "serverMapRestart", idGameLocal::MapRestart_f, CMD_FL_GAME, "restart the current game" );
|
||||
cmdSystem->AddCommand( "serverForceReady", idMultiplayerGame::ForceReady_f,CMD_FL_GAME, "force all players ready" );
|
||||
cmdSystem->AddCommand( "serverNextMap", idGameLocal::NextMap_f, CMD_FL_GAME, "change to the next map" );
|
||||
#endif
|
||||
|
||||
// localization help commands
|
||||
cmdSystem->AddCommand( "nextGUI", Cmd_NextGUI_f, CMD_FL_GAME|CMD_FL_CHEAT, "teleport the player to the next func_static with a gui" );
|
||||
|
|
|
@ -75,17 +75,13 @@ If you have questions concerning this license or the applicable additional terms
|
|||
// compiled out.
|
||||
//#define ID_DEDICATED
|
||||
|
||||
// if this is defined, the executable positively won't work with any paks other
|
||||
// than the demo pak, even if productid is present.
|
||||
//#define ID_DEMO_BUILD
|
||||
|
||||
// don't define ID_ALLOW_TOOLS when we don't want tool code in the executable.
|
||||
#if defined( _WIN32 ) && defined(_MFC_VER) && !defined( ID_DEDICATED ) && !defined( ID_DEMO_BUILD )
|
||||
#if defined( _WIN32 ) && defined(_MFC_VER) && !defined( ID_DEDICATED )
|
||||
#define ID_ALLOW_TOOLS
|
||||
#endif
|
||||
|
||||
#ifndef ID_ENFORCE_KEY
|
||||
# if !defined( ID_DEDICATED ) && !defined( ID_DEMO_BUILD )
|
||||
# if !defined( ID_DEDICATED )
|
||||
# define ID_ENFORCE_KEY 1
|
||||
# else
|
||||
# define ID_ENFORCE_KEY 0
|
||||
|
|
|
@ -2299,7 +2299,7 @@ void idCommonLocal::InitCommands( void ) {
|
|||
cmdSystem->AddCommand( "setMachineSpec", Com_SetMachineSpec_f, CMD_FL_SYSTEM, "detects system capabilities and sets com_machineSpec to appropriate value" );
|
||||
cmdSystem->AddCommand( "execMachineSpec", Com_ExecMachineSpec_f, CMD_FL_SYSTEM, "execs the appropriate config files and sets cvars based on com_machineSpec" );
|
||||
|
||||
#if !defined( ID_DEMO_BUILD ) && !defined( ID_DEDICATED )
|
||||
#if !defined( ID_DEDICATED )
|
||||
// compilers
|
||||
cmdSystem->AddCommand( "dmap", Dmap_f, CMD_FL_TOOL, "compiles a map", idCmdSystem::ArgCompletion_MapName );
|
||||
cmdSystem->AddCommand( "renderbump", RenderBump_f, CMD_FL_TOOL, "renders a bump map", idCmdSystem::ArgCompletion_ModelName );
|
||||
|
|
|
@ -464,7 +464,6 @@ private:
|
|||
void AddGameDirectory( const char *path, const char *dir );
|
||||
void SetupGameDirectories( const char *gameName );
|
||||
void Startup( void );
|
||||
void SetRestrictions( void );
|
||||
// some files can be obtained from directories without compromising si_pure
|
||||
bool FileAllowedFromDir( const char *path );
|
||||
// searches all the paks, no pure check
|
||||
|
@ -859,18 +858,6 @@ const char *idFileSystemLocal::OSPathToRelativePath( const char *OSPath ) {
|
|||
// Ase files from max may have the form of:
|
||||
// "//Purgatory/purgatory/doom/base/models/mapobjects/bitch/hologirl.tga"
|
||||
// which won't match any of our drive letter based search paths
|
||||
bool ignoreWarning = false;
|
||||
#ifdef ID_DEMO_BUILD
|
||||
base = strstr( OSPath, BASE_GAMEDIR );
|
||||
idStr tempStr = OSPath;
|
||||
tempStr.ToLower();
|
||||
if ( ( strstr( tempStr, "//" ) || strstr( tempStr, "w:" ) ) && strstr( tempStr, "/doom/base/") ) {
|
||||
// will cause a warning but will load the file. ase models have
|
||||
// hard coded doom/base/ in the material names
|
||||
base = strstr( OSPath, "base" );
|
||||
ignoreWarning = true;
|
||||
}
|
||||
#else
|
||||
// look for the first complete directory name
|
||||
base = strstr( OSPath, BASE_GAMEDIR );
|
||||
while ( base ) {
|
||||
|
@ -884,7 +871,7 @@ const char *idFileSystemLocal::OSPathToRelativePath( const char *OSPath ) {
|
|||
}
|
||||
base = strstr( base + 1, BASE_GAMEDIR );
|
||||
}
|
||||
#endif
|
||||
|
||||
// fs_game and fs_game_base support - look for first complete name with a mod path
|
||||
// ( fs_game searched before fs_game_base )
|
||||
const char *fsgame = NULL;
|
||||
|
@ -925,9 +912,8 @@ const char *idFileSystemLocal::OSPathToRelativePath( const char *OSPath ) {
|
|||
}
|
||||
}
|
||||
|
||||
if ( !ignoreWarning ) {
|
||||
common->Warning( "idFileSystem::OSPathToRelativePath failed on %s", OSPath );
|
||||
}
|
||||
common->Warning( "idFileSystem::OSPathToRelativePath failed on %s", OSPath );
|
||||
|
||||
strcpy( relativePath, "" );
|
||||
return relativePath;
|
||||
}
|
||||
|
@ -2405,31 +2391,6 @@ void idFileSystemLocal::Startup( void ) {
|
|||
common->Printf( "--------------------------------------\n" );
|
||||
}
|
||||
|
||||
/*
|
||||
===================
|
||||
idFileSystemLocal::SetRestrictions
|
||||
|
||||
Looks for product keys and restricts media add on ability
|
||||
if the full version is not found
|
||||
===================
|
||||
*/
|
||||
void idFileSystemLocal::SetRestrictions( void ) {
|
||||
#ifdef ID_DEMO_BUILD
|
||||
common->Printf( "\nRunning in restricted demo mode.\n\n" );
|
||||
// make sure that the pak file has the header checksum we expect
|
||||
searchpath_t *search;
|
||||
for ( search = searchPaths; search; search = search->next ) {
|
||||
if ( search->pack ) {
|
||||
// a tiny attempt to keep the checksum from being scannable from the exe
|
||||
if ( ( search->pack->checksum ^ 0x84268436u ) != ( DEMO_PAK_CHECKSUM ^ 0x84268436u ) ) {
|
||||
common->FatalError( "Corrupted %s: 0x%x", search->pack->pakFilename.c_str(), search->pack->checksum );
|
||||
}
|
||||
}
|
||||
}
|
||||
cvarSystem->SetCVarBool( "fs_restrict", true );
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
=====================
|
||||
idFileSystemLocal::UpdatePureServerChecksums
|
||||
|
@ -2870,9 +2831,6 @@ void idFileSystemLocal::Init( void ) {
|
|||
// try to start up normally
|
||||
Startup( );
|
||||
|
||||
// see if we are going to allow add-ons
|
||||
SetRestrictions();
|
||||
|
||||
// spawn a thread to handle background file reads
|
||||
StartBackgroundDownloadThread();
|
||||
|
||||
|
@ -2896,9 +2854,6 @@ void idFileSystemLocal::Restart( void ) {
|
|||
|
||||
Startup( );
|
||||
|
||||
// see if we are going to allow add-ons
|
||||
SetRestrictions();
|
||||
|
||||
// if we can't find default.cfg, assume that the paths are
|
||||
// busted and error out now, rather than getting an unreadable
|
||||
// graphics screen when the font fails to load
|
||||
|
|
|
@ -39,11 +39,7 @@ If you have questions concerning this license or the applicable additional terms
|
|||
#define ENGINE_VERSION "dhewm 1.3.1" // printed in console
|
||||
|
||||
// paths
|
||||
#ifdef ID_DEMO_BUILD
|
||||
#define BASE_GAMEDIR "demo"
|
||||
#else
|
||||
#define BASE_GAMEDIR "base"
|
||||
#endif
|
||||
#define BASE_GAMEDIR "base"
|
||||
|
||||
// filenames
|
||||
#define CONFIG_FILE "dhewm.cfg"
|
||||
|
@ -94,11 +90,7 @@ If you have questions concerning this license or the applicable additional terms
|
|||
#define WIN32_CONSOLE_CLASS "dhewm 3 WinConsole"
|
||||
|
||||
// Linux info
|
||||
#ifdef ID_DEMO_BUILD
|
||||
#define LINUX_DEFAULT_PATH "/usr/local/games/dhewm3-demo"
|
||||
#else
|
||||
#define LINUX_DEFAULT_PATH "/usr/local/games/dhewm3"
|
||||
#endif
|
||||
#define LINUX_DEFAULT_PATH "/usr/local/games/dhewm3"
|
||||
|
||||
// CD Key file info
|
||||
// goes into BASE_GAMEDIR whatever the fs_game is set to
|
||||
|
|
|
@ -756,24 +756,6 @@ static void Session_Disconnect_f( const idCmdArgs &args ) {
|
|||
}
|
||||
|
||||
#ifndef ID_DEDICATED
|
||||
#ifdef ID_DEMO_BUILD
|
||||
/*
|
||||
================
|
||||
Session_EndOfDemo_f
|
||||
================
|
||||
*/
|
||||
static void Session_EndOfDemo_f( const idCmdArgs &args ) {
|
||||
sessLocal.Stop();
|
||||
sessLocal.StartMenu();
|
||||
if ( soundSystem ) {
|
||||
soundSystem->SetMute( false );
|
||||
}
|
||||
if ( sessLocal.guiActive ) {
|
||||
sessLocal.guiActive->HandleNamedEvent( "endOfDemo" );
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
================
|
||||
Session_ExitCmdDemo_f
|
||||
|
@ -2828,8 +2810,6 @@ void idSessionLocal::RunGameTic() {
|
|||
SetGUI(guiRestartMenu, NULL);
|
||||
} else if ( !idStr::Icmp( args.Argv(0), "disconnect" ) ) {
|
||||
cmdSystem->BufferCommandText( CMD_EXEC_INSERT, "stoprecording ; disconnect" );
|
||||
} else if ( !idStr::Icmp( args.Argv(0), "endOfDemo" ) ) {
|
||||
cmdSystem->BufferCommandText( CMD_EXEC_NOW, "endOfDemo" );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -2871,10 +2851,6 @@ void idSessionLocal::Init() {
|
|||
|
||||
cmdSystem->AddCommand( "disconnect", Session_Disconnect_f, CMD_FL_SYSTEM, "disconnects from a game" );
|
||||
|
||||
#ifdef ID_DEMO_BUILD
|
||||
cmdSystem->AddCommand( "endOfDemo", Session_EndOfDemo_f, CMD_FL_SYSTEM, "ends the demo version of the game" );
|
||||
#endif
|
||||
|
||||
cmdSystem->AddCommand( "demoShot", Session_DemoShot_f, CMD_FL_SYSTEM, "writes a screenshot for a demo" );
|
||||
cmdSystem->AddCommand( "testGUI", Session_TestGUI_f, CMD_FL_SYSTEM, "tests a gui" );
|
||||
|
||||
|
@ -2901,11 +2877,7 @@ void idSessionLocal::Init() {
|
|||
menuSoundWorld = soundSystem->AllocSoundWorld( rw );
|
||||
|
||||
// we have a single instance of the main menu
|
||||
#ifndef ID_DEMO_BUILD
|
||||
guiMainMenu = uiManager->FindGui( "guis/mainmenu.gui", true, false, true );
|
||||
#else
|
||||
guiMainMenu = uiManager->FindGui( "guis/demo_mainmenu.gui", true, false, true );
|
||||
#endif
|
||||
guiMainMenu_MapList = uiManager->AllocListGUI();
|
||||
guiMainMenu_MapList->Config( guiMainMenu, "mapList" );
|
||||
idAsyncNetwork::client.serverList.GUIConfig( guiMainMenu, "serverList" );
|
||||
|
|
|
@ -314,11 +314,7 @@ void idSessionLocal::SetMainMenuGuiVars( void ) {
|
|||
}
|
||||
|
||||
SetCDKeyGuiVars( );
|
||||
#ifdef ID_DEMO_BUILD
|
||||
guiMainMenu->SetStateString( "nightmare", "0" );
|
||||
#else
|
||||
guiMainMenu->SetStateString( "nightmare", cvarSystem->GetCVarBool( "g_nightmare" ) ? "1" : "0" );
|
||||
#endif
|
||||
guiMainMenu->SetStateString( "browser_levelshot", "guis/assets/splash/pdtempa" );
|
||||
|
||||
SetMainMenuSkin();
|
||||
|
@ -585,11 +581,7 @@ void idSessionLocal::HandleMainMenuCommands( const char *menuCommand ) {
|
|||
if ( icmd < args.Argc() ) {
|
||||
StartNewGame( args.Argv( icmd++ ) );
|
||||
} else {
|
||||
#ifndef ID_DEMO_BUILD
|
||||
StartNewGame( "game/mars_city1" );
|
||||
#else
|
||||
StartNewGame( "game/demo_mars_city1" );
|
||||
#endif
|
||||
}
|
||||
// need to do this here to make sure com_frameTime is correct or the gui activates with a time that
|
||||
// is "however long map load took" time in the past
|
||||
|
|
|
@ -98,7 +98,6 @@ void idAsyncNetwork::Init( void ) {
|
|||
masters[3].var = &master3;
|
||||
masters[4].var = &master4;
|
||||
|
||||
#ifndef ID_DEMO_BUILD
|
||||
cmdSystem->AddCommand( "spawnServer", SpawnServer_f, CMD_FL_SYSTEM, "spawns a server", idCmdSystem::ArgCompletion_MapName );
|
||||
cmdSystem->AddCommand( "nextMap", NextMap_f, CMD_FL_SYSTEM, "loads the next map on the server" );
|
||||
cmdSystem->AddCommand( "connect", Connect_f, CMD_FL_SYSTEM, "connects to a server" );
|
||||
|
@ -111,7 +110,6 @@ void idAsyncNetwork::Init( void ) {
|
|||
cmdSystem->AddCommand( "kick", Kick_f, CMD_FL_SYSTEM, "kick a client by connection number" );
|
||||
cmdSystem->AddCommand( "checkNewVersion", CheckNewVersion_f, CMD_FL_SYSTEM, "check if a new version of the game is available" );
|
||||
cmdSystem->AddCommand( "updateUI", UpdateUI_f, CMD_FL_SYSTEM, "internal - cause a sync down of game-modified userinfo" );
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
@ -3137,14 +3137,12 @@ bool idGameLocal::InhibitEntitySpawn( idDict &spawnArgs ) {
|
|||
}
|
||||
|
||||
const char *name;
|
||||
#ifndef ID_DEMO_BUILD
|
||||
if ( g_skill.GetInteger() == 3 ) {
|
||||
name = spawnArgs.GetString( "classname" );
|
||||
if ( idStr::Icmp( name, "item_medkit" ) == 0 || idStr::Icmp( name, "item_medkit_small" ) == 0 ) {
|
||||
result = true;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
if ( gameLocal.isMultiplayer ) {
|
||||
name = spawnArgs.GetString( "classname" );
|
||||
|
|
|
@ -401,15 +401,11 @@ void idInventory::RestoreInventory( idPlayer *owner, const idDict &dict ) {
|
|||
// weapons are stored as a number for persistant data, but as strings in the entityDef
|
||||
weapons = dict.GetInt( "weapon_bits", "0" );
|
||||
|
||||
#ifdef ID_DEMO_BUILD
|
||||
Give( owner, dict, "weapon", dict.GetString( "weapon" ), NULL, false );
|
||||
#else
|
||||
if ( g_skill.GetInteger() >= 3 ) {
|
||||
Give( owner, dict, "weapon", dict.GetString( "weapon_nightmare" ), NULL, false );
|
||||
} else {
|
||||
Give( owner, dict, "weapon", dict.GetString( "weapon" ), NULL, false );
|
||||
}
|
||||
#endif
|
||||
|
||||
num = dict.GetInt( "levelTriggers" );
|
||||
for ( i = 0; i < num; i++ ) {
|
||||
|
@ -1589,12 +1585,11 @@ void idPlayer::Spawn( void ) {
|
|||
} else {
|
||||
g_damageScale.SetFloat( 1.0f );
|
||||
g_armorProtection.SetFloat( ( g_skill.GetInteger() < 2 ) ? 0.4f : 0.2f );
|
||||
#ifndef ID_DEMO_BUILD
|
||||
|
||||
if ( g_skill.GetInteger() == 3 ) {
|
||||
healthTake = true;
|
||||
nextHealthTake = gameLocal.time + g_healthTakeTime.GetInteger() * 1000;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -3173,7 +3168,7 @@ void idPlayer::UpdatePowerUps( void ) {
|
|||
nextHealthPulse = gameLocal.time + HEALTHPULSE_TIME;
|
||||
healthPulse = true;
|
||||
}
|
||||
#ifndef ID_DEMO_BUILD
|
||||
|
||||
if ( !gameLocal.inCinematic && influenceActive == 0 && g_skill.GetInteger() == 3 && gameLocal.time > nextHealthTake && !AI_DEAD && health > g_healthTakeLimit.GetInteger() ) {
|
||||
assert( !gameLocal.isClient ); // healthPool never be set on client
|
||||
health -= g_healthTakeAmt.GetInteger();
|
||||
|
@ -3183,7 +3178,6 @@ void idPlayer::UpdatePowerUps( void ) {
|
|||
nextHealthTake = gameLocal.time + g_healthTakeTime.GetInteger() * 1000;
|
||||
healthTake = true;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
@ -196,19 +196,12 @@ idTarget_EndLevel::Event_Activate
|
|||
void idTarget_EndLevel::Event_Activate( idEntity *activator ) {
|
||||
idStr nextMap;
|
||||
|
||||
#ifdef ID_DEMO_BUILD
|
||||
if ( spawnArgs.GetBool( "endOfGame" ) ) {
|
||||
cvarSystem->SetCVarBool( "g_nightmare", true );
|
||||
gameLocal.sessionCommand = "endofDemo";
|
||||
return;
|
||||
}
|
||||
#else
|
||||
if ( spawnArgs.GetBool( "endOfGame" ) ) {
|
||||
cvarSystem->SetCVarBool( "g_nightmare", true );
|
||||
gameLocal.sessionCommand = "disconnect";
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
if ( !spawnArgs.GetString( "nextMap", "", nextMap ) ) {
|
||||
gameLocal.Printf( "idTarget_SessionCommand::Event_Activate: no nextMap key\n" );
|
||||
return;
|
||||
|
|
|
@ -2380,7 +2380,6 @@ void idGameLocal::InitConsoleCommands( void ) {
|
|||
cmdSystem->AddCommand( "clearLights", Cmd_ClearLights_f, CMD_FL_GAME|CMD_FL_CHEAT, "clears all lights" );
|
||||
cmdSystem->AddCommand( "gameError", Cmd_GameError_f, CMD_FL_GAME|CMD_FL_CHEAT, "causes a game error" );
|
||||
|
||||
#ifndef ID_DEMO_BUILD
|
||||
cmdSystem->AddCommand( "disasmScript", Cmd_DisasmScript_f, CMD_FL_GAME|CMD_FL_CHEAT, "disassembles script" );
|
||||
cmdSystem->AddCommand( "recordViewNotes", Cmd_RecordViewNotes_f, CMD_FL_GAME|CMD_FL_CHEAT, "record the current view position with notes" );
|
||||
cmdSystem->AddCommand( "showViewNotes", Cmd_ShowViewNotes_f, CMD_FL_GAME|CMD_FL_CHEAT, "show any view notes for the current map, successive calls will cycle to the next note" );
|
||||
|
@ -2400,7 +2399,6 @@ void idGameLocal::InitConsoleCommands( void ) {
|
|||
cmdSystem->AddCommand( "serverMapRestart", idGameLocal::MapRestart_f, CMD_FL_GAME, "restart the current game" );
|
||||
cmdSystem->AddCommand( "serverForceReady", idMultiplayerGame::ForceReady_f,CMD_FL_GAME, "force all players ready" );
|
||||
cmdSystem->AddCommand( "serverNextMap", idGameLocal::NextMap_f, CMD_FL_GAME, "change to the next map" );
|
||||
#endif
|
||||
|
||||
// localization help commands
|
||||
cmdSystem->AddCommand( "nextGUI", Cmd_NextGUI_f, CMD_FL_GAME|CMD_FL_CHEAT, "teleport the player to the next func_static with a gui" );
|
||||
|
|
|
@ -51,11 +51,7 @@ static idStr savepath;
|
|||
==============
|
||||
*/
|
||||
const char *Sys_DefaultSavePath(void) {
|
||||
#if defined( ID_DEMO_BUILD )
|
||||
sprintf( savepath, "%s/.doom3-demo", getenv( "HOME" ) );
|
||||
#else
|
||||
sprintf( savepath, "%s/.doom3", getenv( "HOME" ) );
|
||||
#endif
|
||||
return savepath.c_str();
|
||||
}
|
||||
/*
|
||||
|
|
|
@ -68,11 +68,7 @@ Sys_DefaultSavePath
|
|||
*/
|
||||
const char *Sys_DefaultSavePath(void) {
|
||||
static char savepath[ MAXPATHLEN ];
|
||||
#if defined( ID_DEMO_BUILD )
|
||||
sprintf( savepath, "%s/Library/Application Support/Doom 3 Demo", [NSHomeDirectory() cString] );
|
||||
#else
|
||||
sprintf( savepath, "%s/Library/Application Support/Doom 3", [NSHomeDirectory() cString] );
|
||||
#endif
|
||||
return savepath;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue