engine: expose world BSP version through world global structure
This commit is contained in:
parent
f6fecce52b
commit
46c61660cf
3 changed files with 4 additions and 0 deletions
|
@ -2998,6 +2998,7 @@ static qboolean Mod_LoadBmodelLumps( model_t *mod, const byte *mod_base, qboolea
|
||||||
|
|
||||||
if( isworld )
|
if( isworld )
|
||||||
{
|
{
|
||||||
|
world.version = bmod->version;
|
||||||
#if !XASH_DEDICATED
|
#if !XASH_DEDICATED
|
||||||
Mod_InitDebugHulls( mod ); // FIXME: build hulls for separate bmodels (shells, medkits etc)
|
Mod_InitDebugHulls( mod ); // FIXME: build hulls for separate bmodels (shells, medkits etc)
|
||||||
world.deluxedata = bmod->deluxedata_out; // deluxemap data pointer
|
world.deluxedata = bmod->deluxedata_out; // deluxemap data pointer
|
||||||
|
|
|
@ -113,6 +113,8 @@ typedef struct world_static_s
|
||||||
// tree visualization stuff
|
// tree visualization stuff
|
||||||
int recursion_level;
|
int recursion_level;
|
||||||
int max_recursion;
|
int max_recursion;
|
||||||
|
|
||||||
|
uint32_t version; // BSP version
|
||||||
} world_static_t;
|
} world_static_t;
|
||||||
|
|
||||||
#ifndef REF_DLL
|
#ifndef REF_DLL
|
||||||
|
|
|
@ -111,6 +111,7 @@ void Mod_FreeModel( model_t *mod )
|
||||||
|
|
||||||
if( mod->type == mod_brush && FBitSet( mod->flags, MODEL_WORLD ) )
|
if( mod->type == mod_brush && FBitSet( mod->flags, MODEL_WORLD ) )
|
||||||
{
|
{
|
||||||
|
world.version = 0;
|
||||||
world.shadowdata = NULL;
|
world.shadowdata = NULL;
|
||||||
world.deluxedata = NULL;
|
world.deluxedata = NULL;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue