mirror of
https://github.com/dhewm/dhewm3.git
synced 2024-11-23 21:02:11 +00:00
Fall back to fs_basedir for cd keys
The windows cd installer and steam write it to that location.
This commit is contained in:
parent
90bd14564f
commit
2052928433
1 changed files with 10 additions and 0 deletions
|
@ -2961,6 +2961,11 @@ void idSessionLocal::ReadCDKey( void ) {
|
|||
|
||||
filename = "../" BASE_GAMEDIR "/" CDKEY_FILE;
|
||||
f = fileSystem->OpenExplicitFileRead( fileSystem->RelativePathToOSPath( filename, "fs_configpath" ) );
|
||||
|
||||
// try the install path, which is where the cd installer and steam put it
|
||||
if ( !f )
|
||||
f = fileSystem->OpenExplicitFileRead( fileSystem->RelativePathToOSPath( filename, "fs_basepath" ) );
|
||||
|
||||
if ( !f ) {
|
||||
common->Printf( "Couldn't read %s.\n", filename.c_str() );
|
||||
cdkey[ 0 ] = '\0';
|
||||
|
@ -2975,6 +2980,11 @@ void idSessionLocal::ReadCDKey( void ) {
|
|||
|
||||
filename = "../" BASE_GAMEDIR "/" XPKEY_FILE;
|
||||
f = fileSystem->OpenExplicitFileRead( fileSystem->RelativePathToOSPath( filename, "fs_configpath" ) );
|
||||
|
||||
// try the install path, which is where the cd installer and steam put it
|
||||
if ( !f )
|
||||
f = fileSystem->OpenExplicitFileRead( fileSystem->RelativePathToOSPath( filename, "fs_basepath" ) );
|
||||
|
||||
if ( !f ) {
|
||||
common->Printf( "Couldn't read %s.\n", filename.c_str() );
|
||||
xpkey[ 0 ] = '\0';
|
||||
|
|
Loading…
Reference in a new issue