PTC and FPS problems
Hello. Problem is that if i call PTC in Present i expirience a huge FPS lags. If i add a lot features my FPS becomes less than 15, but normally (without PTC but with menu and hooked dip for wallhack/chams) i have ~80-90! If i add more than 4 features game becomes unplayable.
Here is the PTC function that i use:
With this now i got ~30-35 from normally 90! Also i tried Nightmare's hotkeys base that hook Present but doesn't do any drawing on the screen and still have a performance issues. It is possible to use PTC and have a normal gameplay with the same time? Maybe it's possible to call it in another d3d function which doesn't works so slowly but doesn't have an ideas which one is better or maybe other ideas i'll be very glad if you help here a little.
Here is the PTC function that i use:
Code:
void PushToConsole( const char* Command )
{
DWORD *Adress = ( DWORD* ) LTClientEXE;
if ( *(BYTE *) GameStatus )
{
__asm
{
PUSHAD;
PUSH Command
CALL Adress
ADD ESP, 0x4
POPAD;
}
}
}
Code:
HRESULT WINAPI myPresent(LPDIRECT3DDEVICE9 pDevice, const RECT *a, const RECT *b, HWND c, const RGNDATA *d)
{
// call menu and other shit
if ( NxChams )
PushToConsole("SkelModelStencil 1.0");
else
PushToConsole("SkelModelStencil 0.0");
if ( Fog )
PushToConsole("FogEnable 1.0");
else
PushToConsole("FogEnable 0.0");
if ( Fullbright )
PushToConsole("FullBright 1");
else
PushToConsole("FullBright 0");
return pPresent(pDevice, a, b, c, d);
}

.