1
0
mirror of https://github.com/YGGverse/hlsdk-portable.git synced 2025-03-11 13:01:12 +00:00

Make gPhysicsInterfaceInitialized public

This commit is contained in:
a1batross 2017-01-21 01:23:16 +03:00
parent fa181d8332
commit ed0449448d
2 changed files with 4 additions and 0 deletions

@ -19,6 +19,7 @@
#include "physint.h"
// Must be provided by user of this code
extern BOOL gPhysicsInterfaceInitialized;
extern server_physics_api_t g_physfuncs;
// The actual physic callbacks

@ -822,6 +822,8 @@ static physics_interface_t gPhysicsInterface =
DispatchPhysicsEntity,
};
BOOL gPhysicsInterfaceInitialized = FALSE;
int Server_GetPhysicsInterface( int iVersion, server_physics_api_t *pfuncsFromEngine, physics_interface_t *pFunctionTable )
{
if( !pFunctionTable || !pfuncsFromEngine || iVersion != SV_PHYSICS_INTERFACE_VERSION )
@ -835,5 +837,6 @@ int Server_GetPhysicsInterface( int iVersion, server_physics_api_t *pfuncsFromEn
// fill engine callbacks
memcpy( pFunctionTable, &gPhysicsInterface, sizeof(physics_interface_t) );
gPhysicsInterfaceInitialized = TRUE;
return TRUE;
}