SteeL
02-21-2008, 01:20 AM
Is it correct !! >>
void Writelong(long addy, long value)
{
memory();
WriteProcessMemory(hProcess, (LPVOID*)(DWORD) addy, &value, sizeof(value), NULL);
}
void WritePointerFloat(long addy, short offset, float value)
{
long maddy;
long saddy;
memory();
ReadProcessMemory(hProcess, (LPVOID*)(DWORD) addy, &maddy, sizeof(maddy), NULL);
saddy = maddy + offset;
WriteProcessMemory(hProcess, (LPVOID*)(DWORD) saddy, &value, sizeof(value), NULL);
}
void ReadPointerFloat(long addy, short offset)
{
long maddy;
long saddy;
float value=NULL;
memory();
ReadProcessMemory(hProcess, (LPVOID*)(DWORD) addy, &maddy, sizeof(maddy), NULL);
saddy = maddy + offset;
ReadProcessMemory(hProcess, (LPVOID*)(DWORD) saddy, &value, sizeof(value), NULL);
}
void Readlong(long addy, long value)
{
memory();
WriteProcessMemory(hProcess, (LPVOID*)(DWORD) addy, &value, sizeof(value), NULL);
}
void CWrhak1stDlg::OnStaminaOn()
{
SetTimer(FIRSTTIMER, 1, NULL);
}
void CWrhak1stDlg::OnStaminaOff()
{
KillTimer(FIRSTTIMER);
}
void CWrhak1stDlg::OnTimer(UINT nIDEvent)
{
switch(nIDEvent)
{
case FIRSTTIMER:
{
//stamina
long ST1;
long ST2;
Readlong (0x1332A20, ST1);
ST2 = ST1 + 648;
Writelong(ST2, 1120403456);
}
break;
}
CDialog::OnTimer(nIDEvent);
}
I just utilized my VB6 code n edited some line.. i'm new in C++ :eek:
i get this ERROR :
C:\Program Files\Microsoft Visual Studio\MyProjects\wrhak1st\wrhak1stDlg.cpp(246) : warning C4700: local variable 'ST1' used without having been initialized
*************
also just need help in Hotkeys.
wht goes in that Hex value after suppose >
if (GetKeyState(VK_VK_DELETE) &2E)
but & is something related to Pointer i guess ! cus & operator will give address of 2E but there is nothing declared to be 2E ? m i correct ! :confused:
void Writelong(long addy, long value)
{
memory();
WriteProcessMemory(hProcess, (LPVOID*)(DWORD) addy, &value, sizeof(value), NULL);
}
void WritePointerFloat(long addy, short offset, float value)
{
long maddy;
long saddy;
memory();
ReadProcessMemory(hProcess, (LPVOID*)(DWORD) addy, &maddy, sizeof(maddy), NULL);
saddy = maddy + offset;
WriteProcessMemory(hProcess, (LPVOID*)(DWORD) saddy, &value, sizeof(value), NULL);
}
void ReadPointerFloat(long addy, short offset)
{
long maddy;
long saddy;
float value=NULL;
memory();
ReadProcessMemory(hProcess, (LPVOID*)(DWORD) addy, &maddy, sizeof(maddy), NULL);
saddy = maddy + offset;
ReadProcessMemory(hProcess, (LPVOID*)(DWORD) saddy, &value, sizeof(value), NULL);
}
void Readlong(long addy, long value)
{
memory();
WriteProcessMemory(hProcess, (LPVOID*)(DWORD) addy, &value, sizeof(value), NULL);
}
void CWrhak1stDlg::OnStaminaOn()
{
SetTimer(FIRSTTIMER, 1, NULL);
}
void CWrhak1stDlg::OnStaminaOff()
{
KillTimer(FIRSTTIMER);
}
void CWrhak1stDlg::OnTimer(UINT nIDEvent)
{
switch(nIDEvent)
{
case FIRSTTIMER:
{
//stamina
long ST1;
long ST2;
Readlong (0x1332A20, ST1);
ST2 = ST1 + 648;
Writelong(ST2, 1120403456);
}
break;
}
CDialog::OnTimer(nIDEvent);
}
I just utilized my VB6 code n edited some line.. i'm new in C++ :eek:
i get this ERROR :
C:\Program Files\Microsoft Visual Studio\MyProjects\wrhak1st\wrhak1stDlg.cpp(246) : warning C4700: local variable 'ST1' used without having been initialized
*************
also just need help in Hotkeys.
wht goes in that Hex value after suppose >
if (GetKeyState(VK_VK_DELETE) &2E)
but & is something related to Pointer i guess ! cus & operator will give address of 2E but there is nothing declared to be 2E ? m i correct ! :confused: