long WINAPI hkPresent( IDirect3DDevice9* pDevice, RECT* pSrcRect, RECT* pDescRect, HWND pHWND, RGNDATA* pRegion )
{
ImGui_ImplDX9_NewFrame( );
ImGui_ImplWin32_NewFrame( );
ImGui::NewFrame( );
g_ESP->Render();
ImGui::Render();
ImGui_ImplDX9_RenderDrawData( ImGui::GetDrawData( ) );
pDevice->EndScene( );
return oPresent(pDevice, pSrcRect, pDescRect, pHWND, pRegion);
}
//--------------------------------------------------------------------------------
long WINAPI hkReset( IDirect3DDevice9* pDevice, D3DPRESENT_PARAMETERS* pDeviceParameters )
{
g_ESP->OnDeviceLost();
auto hr = oReset(pDevice, pDeviceParameters);
if (hr >= 0)
g_ESP->OnDeviceReset();
return hr;
}