From 6b918aef869b14c3cc4cf5ca6244c7ef6c2df0d6 Mon Sep 17 00:00:00 2001 From: Robert Beckebans Date: Wed, 19 Dec 2012 23:56:20 +0100 Subject: [PATCH] Disabled broken savegame and profile storage checks for the PC --- README.txt | 19 ++++++++++--------- neo/framework/Common.cpp | 6 +++++- neo/sys/sys_localuser.cpp | 8 ++++++-- neo/sys/sys_localuser.h | 5 ++++- neo/sys/win32/win_savegame.cpp | 6 +++++- 5 files changed, 30 insertions(+), 14 deletions(-) diff --git a/README.txt b/README.txt index 2044193a..555482bd 100644 --- a/README.txt +++ b/README.txt @@ -1,10 +1,9 @@ -____________________________ _____________________________________ -\______ \______ \______ \ ____ ____ _____ \_____ \______ \_ _____/ _____/ - | _/| | _/| | \ / _ \ / _ \ / \ _(__ <| | _/| __)/ \ ___ - | | \| | \| ` ( <_> | <_> ) Y Y \/ \ | \| \ \ \_\ \ - |____|_ /|______ /_______ /\____/ \____/|__|_| /______ /______ /\___ / \______ / - \/ \/ \/ \/ \/ \/ \/ + ____ ____ ____ _____ ____ ______ ______ + / __ \ / __ ) / __ \ ____ ____ ____ ___ |__ / / __ ) / ____// ____/ + / /_/ // __ |/ / / // __ \ / __ \ / __ `__ \ /_ < / __ |/ /_ / / __ + / _, _// /_/ // /_/ // /_/ // /_/ // / / / / /___/ // /_/ // __/ / /_/ / +/_/ |_|/_____//_____/ \____/ \____//_/ /_/ /_//____//_____//_/ \____/ _________________________________________ @@ -150,14 +149,14 @@ _________________________ On Debian or Ubuntu: - > apt-get install libsdl1.2-dev cmake + > apt-get install cmake libsdl1.2-dev On Fedora - > yum install SDL-devel cmake + > yum install cmake SDL-devel -3. Generate the Makefiles using Premake: +3. Generate the Makefiles using CMake: > cd neo/ > ./cmake-eclipse-linux-profile.sh @@ -191,7 +190,9 @@ ___________________________________________________ __________________________________________ * Sound engine does not work on Linux + * Doomclassic is not supported on Linux (yet) * There are some issues with the binary format loaders/writers on 64 bit platforms + * The intel open source drivers to not support OpenGL 3.2 yet ___________________________________________________ diff --git a/neo/framework/Common.cpp b/neo/framework/Common.cpp index e426b70b..cdcab498 100644 --- a/neo/framework/Common.cpp +++ b/neo/framework/Common.cpp @@ -634,7 +634,10 @@ idCommonLocal::CheckStartupStorageRequirements */ void idCommonLocal::CheckStartupStorageRequirements() { + // RB: disabled savegame and profile storage checks, because it fails sometimes without any clear reason +#if 0 int64 availableSpace = 0; + // ------------------------------------------------------------------------ // Savegame and Profile required storage // ------------------------------------------------------------------------ @@ -711,7 +714,8 @@ void idCommonLocal::CheckStartupStorageRequirements() common->Dialog().AddDynamicDialog( GDM_INSUFFICENT_STORAGE_SPACE, callbacks, optionText, true, msg ); } - +#endif + // RB end session->GetAchievementSystem().Start(); } diff --git a/neo/sys/sys_localuser.cpp b/neo/sys/sys_localuser.cpp index 1ece3b20..a23807ee 100644 --- a/neo/sys/sys_localuser.cpp +++ b/neo/sys/sys_localuser.cpp @@ -89,18 +89,22 @@ void idLocalUser::ResetStorageDevice() idLocalUser::StorageSizeAvailable ======================== */ +// RB: disabled savegame and profile storage checks, because it fails sometimes without any clear reason +/* bool idLocalUser::StorageSizeAvailable( uint64 minSizeInBytes, int64& neededBytes ) { int64 size = Sys_GetDriveFreeSpaceInBytes( fs_savepath.GetString() ); - + neededBytes = minSizeInBytes - size; if( neededBytes < 0 ) { neededBytes = 0; } - + return neededBytes == 0; } +*/ +// RB end /* ======================== diff --git a/neo/sys/sys_localuser.h b/neo/sys/sys_localuser.h index 9cad24c6..7c3dd679 100644 --- a/neo/sys/sys_localuser.h +++ b/neo/sys/sys_localuser.h @@ -125,7 +125,10 @@ public: // Storage related virtual bool IsStorageDeviceAvailable() const; // Only false if the player has chosen to play without a storage device, only possible on 360, if available, everything needs to check for available space virtual void ResetStorageDevice(); - virtual bool StorageSizeAvailable( uint64 minSizeInBytes, int64& neededBytes ); + + // RB: disabled savegame and profile storage checks, because it fails sometimes without any clear reason + //virtual bool StorageSizeAvailable( uint64 minSizeInBytes, int64& neededBytes ); + // RB end // These set stats within the profile as a enum/value pair virtual void SetStatInt( int stat, int value ); diff --git a/neo/sys/win32/win_savegame.cpp b/neo/sys/win32/win_savegame.cpp index 5187a8d4..a6a1f24e 100644 --- a/neo/sys/win32/win_savegame.cpp +++ b/neo/sys/win32/win_savegame.cpp @@ -132,6 +132,8 @@ int idSaveGameThread::Save() } } + // RB: disabled savegame and profile storage checks, because it fails sometimes without any clear reason + /* // Inform user about size required if necessary if( requiredSizeBytes > 0 && !callback->cancelled ) { @@ -143,7 +145,7 @@ int idSaveGameThread::Save() directory += "\\"; // so it doesn't think the last part is a file and ignores in the directory creation fileSystem->CreateOSPath( directory ); // we can't actually check FileExists in production builds, so just try to create it user->StorageSizeAvailable( requiredSizeBytes, callback->requiredSpaceInBytes ); - + if( callback->requiredSpaceInBytes > 0 ) { callback->errorCode = SAVEGAME_E_INSUFFICIENT_ROOM; @@ -152,6 +154,8 @@ int idSaveGameThread::Save() } } } + */ + // RB end // Delete all previous files if needed // ALL THE FILES RIGHT NOW---- could use pattern later...