better physics
This commit is contained in:
@@ -16,8 +16,10 @@
|
||||
#endif
|
||||
|
||||
IFileSystem *filesystem;
|
||||
|
||||
IRenderContext *g_pRenderContext;
|
||||
IGameWindow *g_pMainWindow;
|
||||
|
||||
static CEngineVars s_vars;
|
||||
CEngineVars *g_pEngineVars = &s_vars;
|
||||
EngineConsts_t *g_pEngineConstants;
|
||||
@@ -25,6 +27,9 @@ EngineConsts_t *g_pEngineConstants;
|
||||
INetworkBase *g_pServerBridge;
|
||||
INetworkBase *g_pServerConnection;
|
||||
|
||||
IPhysics *g_pPhysics;
|
||||
IPhysicsWorld *g_pPhysicsWorld;
|
||||
|
||||
class CFunnyGameBridge: public IEngineBridge
|
||||
{
|
||||
virtual void Init() override;
|
||||
@@ -70,6 +75,10 @@ void CFunnyGameBridge::Init()
|
||||
};
|
||||
g_pServerBridge->SendPacket({&join, sizeof(join)});
|
||||
}
|
||||
|
||||
CreateInterfaceFn fnPhysicsFactory = Sys_GetFactory("RapierPhysics");
|
||||
g_pPhysics = (IPhysics*)fnPhysicsFactory(PHYSICS_INTERFACE_VERSION, NULL);
|
||||
g_pPhysicsWorld = g_pPhysics->CreateWorld();
|
||||
}
|
||||
|
||||
void CFunnyGameBridge::Tick( float fDelta )
|
||||
|
||||
Reference in New Issue
Block a user