diff options
author | Andrey Nazarov <skuller@skuller.net> | 2008-08-16 10:19:42 +0000 |
---|---|---|
committer | Andrey Nazarov <skuller@skuller.net> | 2008-08-16 10:19:42 +0000 |
commit | 1526e22e4ff29153e9c127081e8ea8d9e2f33b8c (patch) | |
tree | b361766433d4a7b4a111865afd52803e2bbf7754 /source/sv_init.c | |
parent | e826e5f176f21cd18b3bbc22887a266835ada57c (diff) |
Split some monolithic include files into smaller ones.
Use single BSP models cache for refresh and collision subsystems.
Refresh libraries may not longer be dynamically loaded.
Made gi.TagMalloc use separate tag namespace to avoid
conflicts with engine reserverd tags.
Fixed listing order of MVD channels in chooser menu.
A lot of misc changes... MSVC build is definitely broken now.
Diffstat (limited to 'source/sv_init.c')
-rw-r--r-- | source/sv_init.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/source/sv_init.c b/source/sv_init.c index b3b062f..c697024 100644 --- a/source/sv_init.c +++ b/source/sv_init.c @@ -96,7 +96,7 @@ static void SV_SpawnServer( cm_t *cm, const char *server, const char *spawnpoint sprintf( sv.configstrings[CS_MAPCHECKSUM], "%d", ( int )cm->cache->checksum ); - for( i = 1; i < sv.cm.cache->numcmodels; i++ ) { + for( i = 1; i < sv.cm.cache->nummodels; i++ ) { sprintf( sv.configstrings[ CS_MODELS + 1 + i ], "*%d", i ); } @@ -114,7 +114,7 @@ static void SV_SpawnServer( cm_t *cm, const char *server, const char *spawnpoint sv.state = ss_loading; // load and spawn all other entities - ge->SpawnEntities ( sv.name, CM_EntityString( &sv.cm ), spawnpoint ); + ge->SpawnEntities ( sv.name, cm->cache->entitystring, spawnpoint ); // run two frames to allow everything to settle ge->RunFrame (); @@ -312,8 +312,6 @@ void SV_Map (const char *levelstring, qboolean restart) { char expanded[MAX_QPATH]; char *ch; cm_t cm; - uint32_t checksum; - const char *error; // skip the end-of-unit flag if necessary if( *levelstring == '*' ) { @@ -342,8 +340,8 @@ void SV_Map (const char *levelstring, qboolean restart) { } Q_concat( expanded, sizeof( expanded ), "maps/", level, ".bsp", NULL ); - if( ( error = CM_LoadMapEx( &cm, expanded, 0, &checksum ) ) != NULL ) { - Com_Printf( "Couldn't load %s: %s\n", expanded, error ); + if( !CM_LoadMap( &cm, expanded ) ) { + Com_Printf( "Couldn't load %s: %s\n", expanded, BSP_GetError() ); return; } |