diff options
author | Andrey Nazarov <skuller@skuller.net> | 2007-12-07 17:29:24 +0000 |
---|---|---|
committer | Andrey Nazarov <skuller@skuller.net> | 2007-12-07 17:29:24 +0000 |
commit | 439dd89a479e2d02fa40a421849c73616f92198e (patch) | |
tree | 96731a474ea0198a611f5fa03bcb360119d212a2 /source/ui_playermodels.c | |
parent | 5c30b8152eb6a0fae6e50dbd834d73a2846df4ec (diff) |
Optimized FS_ListFiles (and broken Windows build).
Initial changes to demo browser to support caching.
Diffstat (limited to 'source/ui_playermodels.c')
-rw-r--r-- | source/ui_playermodels.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/source/ui_playermodels.c b/source/ui_playermodels.c index ac2e589..83f22a7 100644 --- a/source/ui_playermodels.c +++ b/source/ui_playermodels.c @@ -93,7 +93,7 @@ void PlayerModel_Load( void ) { /* ** get a list of directories */ - if( !( list = fs.ListFiles( NULL, "players/*/*", FS_SEARCH_BYFILTER|FS_SEARCH_SAVEPATH, &numFiles ) ) ) { + if( !( list = ( char ** )fs.ListFiles( NULL, "players/*/*", FS_SEARCH_BYFILTER|FS_SEARCH_SAVEPATH, &numFiles ) ) ) { return; } @@ -119,7 +119,7 @@ void PlayerModel_Load( void ) { } } - fs.FreeFileList( list ); + fs.FreeList( ( void ** )list ); if( !ndirs ) { return; @@ -146,7 +146,7 @@ void PlayerModel_Load( void ) { // verify the existence of at least one pcx skin Q_concat( scratch, sizeof( scratch ), "players/", dirnames[i], NULL ); - pcxnames = fs.ListFiles( scratch, ".pcx", 0, &npcxfiles ); + pcxnames = ( char ** )fs.ListFiles( scratch, ".pcx", 0, &npcxfiles ); if( !pcxnames ) { continue; } @@ -161,7 +161,7 @@ void PlayerModel_Load( void ) { } if( !nskins ) { - fs.FreeFileList( pcxnames ); + fs.FreeList( ( void ** )pcxnames ); continue; } @@ -178,11 +178,11 @@ void PlayerModel_Load( void ) { } } - fs.FreeFileList( pcxnames ); + fs.FreeList( ( void ** )pcxnames ); // load vweap models Q_concat( scratch, sizeof( scratch ), "players/", dirnames[i], "/w_*.md2", NULL ); - weaponNames = fs.ListFiles( NULL, scratch, FS_SEARCH_BYFILTER, &numWeapons ); + weaponNames = ( char ** )fs.ListFiles( NULL, scratch, FS_SEARCH_BYFILTER, &numWeapons ); pmi = &uis.pmi[uis.numPlayerModels++]; pmi->numWeapons = 0; @@ -199,7 +199,7 @@ void PlayerModel_Load( void ) { } } - fs.FreeFileList( weaponNames ); + fs.FreeList( ( void ** )weaponNames ); } // at this point we have a valid player model |