自已解决了!原来是我的在写CALL时把一个代码给搞错了!
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include "汇编模块.au3"
run("游戏找CALL练习实例one.exe")
Dim $pid,$id,$Win="写CALL测试"
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate($Win, 330, 228, 193, 125)
$Button1 = GUICtrlCreateButton("取PID", 120, 24, 75, 25, 0)
$Button2 = GUICtrlCreateButton("吃红", 56, 80, 75, 25, 0)
$Button3 = GUICtrlCreateButton("吃蓝", 56, 112, 75, 25, 0)
$Button4 = GUICtrlCreateButton("回城", 176, 80, 75, 25, 0)
$Button5 = GUICtrlCreateButton("冰系", 56, 160, 75, 25, 0)
$Button6 = GUICtrlCreateButton("火系", 176, 160, 75, 25, 0)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Button1
$Hawd=WinGetHandle("游戏找CALL练习实例one")
If $Hawd<>0 Then
GetWindowThreadProcessId($Hawd,$Pid)
$hd=OpenProcess($PROCESS_ALL_ACCESS, False,$pid)
If $hd=0 Then
MsgBox(0,$Win,"打不开进程")
Else
MsgBox(0,"取窗口ID","窗口句柄:"&$Hawd&" 窗口PID:"&$pid&" 打开进程:"&$hd)
EndIf
CloseHandle($hd)
Else
MsgBox(0,$Win,"找不到 游戏找CALL练习实例one 的进程ID")
EndIf
Case $Button2
If $pid<>"" Then
Pushad()
MOV_EBX (0x00d547fc)
Mov_EAX_DWORD_Ptr_EBX_Add(0x124)
Mov_EDX_DWORD_Ptr_EBX_Add(0x120)
Call_EDX()
Popad()
Ret()
Run_ASM($pid)
TrayTip($Win,"吃红",5)
Else
TrayTip($Win,"未获取PID",5)
EndIf
Case $Button3
If $pid<>"" Then
Pushad()
MOV_EBX (0x00D5450C)
Mov_EAX_DWORD_Ptr_EBX_Add(0x124)
Mov_EDX_DWORD_Ptr_EBX_Add(0x120)
Call_EDX()
Popad()
Ret()
Run_ASM ($pid)
TrayTip($Win,"吃蓝",5)
Else
TrayTip($Win,"未获取PID",5)
EndIf
Case $Button4
If $pid<>"" Then
Pushad()
MOV_EBX (0x00D5412C)
Mov_EAX_DWORD_Ptr_EBX_Add(0x124)
Mov_EDX_DWORD_Ptr_EBX_Add(0x120)
Call_EDX()
Popad()
Ret()
Run_ASM ($pid)
TrayTip($Win,"回城",5)
Else
TrayTip($Win,"未获取PID",5)
EndIf
Case $Button5
If $pid<>"" Then
Pushad()
MOV_EBX (0x00D54EB0)
Mov_EAX_DWORD_Ptr_EBX_Add(0x124)
Mov_EDX_DWORD_Ptr_EBX_Add(0x120)
Call_EDX()
Popad()
Ret()
Run_ASM ($pid)
TrayTip($Win,"冰系",5)
Else
TrayTip($Win,"未获取PID",5)
EndIf
Case $Button6
If $pid<>"" Then
Pushad()
MOV_EBX (0x00D552D4)
Mov_EAX_DWORD_Ptr_EBX_Add(0x124)
Mov_EDX_DWORD_Ptr_EBX_Add(0x120)
Call_EDX()
Popad()
Ret()
Run_ASM ($pid)
TrayTip($Win,"火系",5)
Else
TrayTip($Win,"未获取PID",5)
EndIf
EndSwitch
WEnd
[ 本帖最后由 ≈※爖※≈ 于 2009-1-14 14:39 编辑 ] |