i use to do that but result is terminated and back to my desktop.....
my addys was also updated,....
---------- Post added at 09:27 PM ---------- Previous post was at 09:25 PM ----------

Originally Posted by
.Joker
Use [CODE] "[ / CODE ] function
Do you have CPatch.cpp ?
yes i have CPatch.cpp,
how will i use that code function?.....
---------- Post added at 09:29 PM ---------- Previous post was at 09:27 PM ----------

Originally Posted by
.Joker
Use [CODE] "[ / CODE ] function
Do you have CPatch.cpp ?
this is the CPatch.cpp
#include "CPatch.h"
void* CPatch::memcpy_s(void *pvAddress, const void *pvBuffer, size_t stLen)
{
MEMORY_BASIC_INFORMATION mbi;
VirtualQuery( ( void* )pvAddress, &mbi, sizeof( mbi ) );
VirtualProtect( mbi.BaseAddress, mbi.RegionSize, PAGE_EXECUTE_READWRITE, &mbi.Protect );
void* pvRetn = memcpy( ( void* )pvAddress, ( void* )pvBuffer, stLen );
VirtualProtect( mbi.BaseAddress, mbi.RegionSize, mbi.Protect, &mbi.Protect );
FlushInstructionCache( GetCurrentProcess( ), ( void* )pvAddress, stLen );
return pvRetn;
}
CPatch::CPatch(DWORD g_T_ADR, int s_RESTORE_BYTES)
{
T_RESTOREPATCH = false;
T_ONCE = false;
g_s_RESTORE_BYTES = s_RESTORE_BYTES;
T_ADR = g_T_ADR;
for( int i = 0; i < 6; i++ )
{
T_RESTORE_BYTES[i] = 0x00;
}
}
void CPatch::PatchOnce(const void* T_SRC, int s_T_SRC)
{
if( !T_ONCE )
{
T_ONCE = true;
T_RESTOREPATCH = true;
BYTE *g_T_RESTORE_BYTES = (BYTE*)T_ADR;
for( int i = 0; i < g_s_RESTORE_BYTES; i++ )
{
T_RESTORE_BYTES[i] = g_T_RESTORE_BYTES[i];
}
memcpy_s((void*)T_ADR, (const void*)T_SRC, s_T_SRC);
}
}
void CPatch::RestorePatch()
{
if( T_RESTOREPATCH )
{
BYTE *g_T_ADR = (BYTE*)T_ADR;
for( int i = 0; i < g_s_RESTORE_BYTES; i++ )
{
g_T_ADR[i] = T_RESTORE_BYTES[i];
}
T_RESTOREPATCH = false;
T_ONCE = false;
}
}
---Q----
what will i do for the code function?