Source release of Wolfenstein 3D Classic Platinum for iOS, 2.1

This commit is contained in:
Travis Bradshaw
2012-01-31 17:08:50 -06:00
parent 16304944b4
commit d7fff51d7d
235 changed files with 64191 additions and 1418 deletions

View File

@@ -172,7 +172,16 @@ PRIVATE char **FS_ListFiles( char *findname, int *numfiles, unsigned musthave, u
*/
PUBLIC void FS_InitFilesystem( void )
{
char *p;
p = getenv("CWD");
sprintf( fs_gamedir, "%s/base", p );
#define BASE_DIRECTORY "/base"
int length = SysIPhoneGetPathToMainBundleLength();
// Make sure the path will fit.
int fullPathLength = length + strlen( BASE_DIRECTORY ) + 1;
assert( fullPathLength < MAX_OSPATH );
SysIPhoneGetPathToMainBundle( fs_gamedir, length + 1 );
strcpy( fs_gamedir + length, BASE_DIRECTORY );
}