That was a great tutorial; Thank you very much for the link.
That's the most informative video I have seen on this topic. Are you the maker of the video? I've subscribed anyway. Oh, and I turned it into C code, as it looks better imo.
Code:
#include <stdio.h>
#include <windows.h>
int main()
{
int newValue = 500;
HWND hWnd = FindWindow(0, "Calculator");
if (hWnd == 0) {
fprintf(stderr, "Cannot find window.");
} else {
DWORD pId;
GetWindowThreadProcessId(hWnd, &pId);
HANDLE hProc = OpenProcess(PROCESS_ALL_ACCESS, FALSE, pId);
if (!hProc) {
fprintf(stderr, "Cannot open process.");
} else {
int isSuccessful = WriteProcessMemory(hProc, (LPVOID)0x000AFCC4, &newValue, (DWORD)sizeof(newValue), NULL);
if (isSuccessful > 0) {
puts("Process memory written.");
} else {
fprintf(stderr, "Cannot write process memory.");
}
CloseHandle(hProc);
}
}
getchar();
return 0;
}