Skip to content

Commit

Permalink
Bring back ui fallback
Browse files Browse the repository at this point in the history
  • Loading branch information
ensiform committed May 5, 2024
1 parent 30b4aec commit e1840e5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/unix/unix_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -832,7 +832,7 @@ void *Sys_LoadGameDll(const char *name, vmMain_t *entryPoint, dllSyscall_t syste

// Last resort for missing DLLs or media mods
// If mod requires a different cgame/ui this could cause problems
/*if ( !libHandle && strcmp( gamedir, BASEGAME ) != 0 )
if ( !libHandle && !strcmp( name, "ui" ) && strcmp( gamedir, BASEGAME ) != 0 )
{
const char *temp = va( "%s%c%s", gamedir, PATH_SEP, fname );
FS_SetFilterFlag( FS_EXCLUDE_OTHERGAMES );
Expand All @@ -845,7 +845,7 @@ void *Sys_LoadGameDll(const char *name, vmMain_t *entryPoint, dllSyscall_t syste
libHandle = try_dlopen(SEARCHPATH2, BASEGAME, fname);
}
FS_SetFilterFlag( 0 );
}*/
}

if (!libHandle)
{
Expand Down
4 changes: 2 additions & 2 deletions src/win32/win_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -827,15 +827,15 @@ void *QDECL Sys_LoadGameDll( const char *name, vmMain_t *entryPoint, dllSyscall_

// Last resort for missing DLLs or media mods
// If mod requires a different cgame/ui this could cause problems
/*if ( !libHandle && strcmp( gamedir, BASEGAME ) != 0 ) {
if ( !libHandle && !strcmp( name, "ui" ) && strcmp( gamedir, BASEGAME ) != 0 ) {
const char *temp = va( "%s%c%s", gamedir, PATH_SEP, filename );
FS_SetFilterFlag( FS_EXCLUDE_OTHERGAMES );
if ( !FS_SV_FileExists( temp ) && !FS_FileIsInPAK( filename, NULL, NULL ) ) {
Com_Printf( "Sys_LoadDLL(%s/%s) trying %s override\n", gamedir, name, BASEGAME );
libHandle = try_dlopen(basepath, BASEGAME, filename);
}
FS_SetFilterFlag( 0 );
}*/
}

if ( !libHandle ) {
#ifdef _DEBUG // in debug abort on failure
Expand Down

0 comments on commit e1840e5

Please sign in to comment.