int GetLLKLTime()
{
LLK_WIN = ::FindWindow(NULL,"连连看5");
//窗口进程ID
DWORD dwLLKid=0;
GetWindowThreadProcessId(LLK_WIN,&dwLLKid);
//打开指定的进程
//DWORD timeAddress = 0x4C0E2C+0x14;
HANDLE hLLK;
hLLK = OpenProcess(PROCESS_ALL_ACCESS,FALSE,dwLLKid);
//读取一次
DWORD timeAddress = 0x4C0E2C+0x14;
DWORD tempData=0;
ReadProcessMemory(hLLK,(LPCVOID)timeAddress,&tempData,4,NULL);
//读取2次
timeAddress = tempData + 0x20;
tempData = 0;
ReadProcessMemory(hLLK,(LPCVOID)timeAddress,&tempData,4,NULL);
timeAddress = tempData + 0x2C;
tempData = 0;
ReadProcessMemory(hLLK,(LPCVOID)timeAddress,&tempData,4,NULL);
return tempData;
}int GetLLKLTime()
{
LLK_WIN = ::FindWindow(NULL,"连连看5");
//窗口进程ID
DWORD dwLLKid=0;
GetWindowThreadProcessId(LLK_WIN,&dwLLKid);
//打开指定的进程
//DWORD timeAddress = 0x4C0E2C+0x14;
HANDLE hLLK;
hLLK = OpenProcess(PROCESS_ALL_ACCESS,FALSE,dwLLKid);
//读取一次
DWORD timeAddress = 0x4C0E2C+0x14;
DWORD tempData=0;
ReadProcessMemory(hLLK,(LPCVOID)timeAddress,&tempData,4,NULL);
//读取2次
timeAddress = tempData + 0x20;
tempData = 0;
ReadProcessMemory(hLLK,(LPCVOID)timeAddress,&tempData,4,NULL);
timeAddress = tempData + 0x2C;
tempData = 0;
ReadProcessMemory(hLLK,(LPCVOID)timeAddress,&tempData,4,NULL);
return tempData;
}int GetLLKLTime()
{
LLK_WIN = ::FindWindow(NULL,"连连看5");
//窗口进程ID
DWORD dwLLKid=0;
GetWindowThreadProcessId(LLK_WIN,&dwLLKid);
//打开指定的进程
//DWORD timeAddress = 0x4C0E2C+0x14;
HANDLE hLLK;
hLLK = OpenProcess(PROCESS_ALL_ACCESS,FALSE,dwLLKid);
//读取一次
DWORD timeAddress = 0x4C0E2C+0x14;
DWORD tempData=0;
ReadProcessMemory(hLLK,(LPCVOID)timeAddress,&tempData,4,NULL);
//读取2次
timeAddress = tempData + 0x20;
tempData = 0;
ReadProcessMemory(hLLK,(LPCVOID)timeAddress,&tempData,4,NULL);
timeAddress = tempData + 0x2C;
tempData = 0;
ReadProcessMemory(hLLK,(LPCVOID)timeAddress,&tempData,4,NULL);
return tempData;
} |