赞
踩
很简单一个辅助,关键是游戏数据的分析,实现了两个功能,无限阳光和无冷却。特别注意的一下,如果用VS2008编译的话,调试的时候是正常的,但编译后功能就会失效,这是因为OpenProcess权限的问题,需要提权,在VC6下是正常的。
- void CzhiwuDlg::OnBnClickedButton1()
- {
- //无限阳光代码
- HWND hJubing;
- DWORD lID;
- DWORD base = 0x006a9ec0;
- DWORD cunfang;
- hJubing= FindWindowA(NULL,"植物大战僵尸中文版");
- GetWindowThreadProcessId(hJubing,&lID);
- HANDLE hOpen = OpenProcess(PROCESS_ALL_ACCESS,0,lID);
- ReadProcessMemory(hOpen,(LPVOID)base,&cunfang,4,NULL);
- base = cunfang + 0x768;
- ReadProcessMemory(hOpen,(LPVOID)base,&cunfang,4,NULL);
- base = cunfang + 0x5560;
- cunfang=9999;
- WriteProcessMemory(hOpen,(LPVOID)base,&cunfang,4,NULL);
- }
-
- void CzhiwuDlg::OnBnClickedButton2()
- {
- //无冷却时间代码
- DWORD lID;
- DWORD base = 0x00488e73;
- HWND hJuBing = FindWindowA(NULL,"植物大战僵尸中文版");
- GetWindowThreadProcessId(hJuBing,&lID); //获取进程id
- HANDLE hOpen = OpenProcess(PROCESS_ALL_ACCESS,NULL,lID);//打开进程 获取所有操作权限
- DWORD pianyi = 0x80;
- WriteProcessMemory(hOpen,(LPVOID)base,&pianyi,1,NULL);
-
- }
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。