Add GoldSource support

This commit is contained in:
a1batross 2016-08-08 13:37:32 +06:00
parent 9124c049cd
commit 8d3cce7aa2
1 changed files with 19 additions and 0 deletions

View File

@ -146,6 +146,24 @@ int DLLEXPORT Initialize( cl_enginefunc_t *pEnginefuncs, int iVersion )
return 1;
}
/*
=================
HUD_GetRect
VGui stub
=================
*/
int *HUD_GetRect( void )
{
static int extent[4];
extent[0] = gEngfuncs.GetWindowCenterX() - ScreenWidth / 2;
extent[1] = gEngfuncs.GetWindowCenterY() - ScreenHeight / 2;
extent[2] = gEngfuncs.GetWindowCenterX() + ScreenWidth / 2;
extent[3] = gEngfuncs.GetWindowCenterY() + ScreenHeight / 2;
return extent;
}
/*
==========================
@ -241,6 +259,7 @@ Called by engine every frame that client .dll is loaded
void DLLEXPORT HUD_Frame( double time )
{
gEngfuncs.VGui_ViewportPaintBackground(HUD_GetRect());
}