|
发表于 2009-5-8 16:22:54
|
显示全部楼层
引用第1楼actboy168于2009-05-08 15:56发表的 :
地圖駭客是maphack的意思? [s:188][s:188][s:188][s:188]
selectunit函数
试图把最后跳走后(以为)是更新UI的部分改成直接retn,但UI还是变了
指导下
6F3C28D0 MOV ECX,DWORD PTR SS:[ESP+4] ; selectunit
6F3C28D4 PUSH EBX
6F3C28D5 CALL Game.6F3B9EF0 ; 得到单位
6F3C28DA MOV EBX,EAX
6F3C28DC TEST EBX,EBX
6F3C28DE JE Game.6F3C297C
6F3C28E4 MOV EDX,DWORD PTR DS:[EBX+10]
6F3C28E7 MOV ECX,DWORD PTR DS:[EBX+C]
6F3C28EA CALL Game.6F0406B0 ; 取得单位对应的某指针
6F3C28EF TEST EAX,EAX ; 检查指针的对象是否合法
6F3C28F1 JE Game.6F3C297C ; 不合法return
6F3C28F7 XOR ECX,ECX
6F3C28F9 CMP DWORD PTR DS:[EAX+C],2B61676C ; 该指针+C是否agl
6F3C2900 SETNE CL
6F3C2903 SUB ECX,1
6F3C2906 AND ECX,EAX
6F3C2908 MOV EAX,ECX
6F3C290A JE SHORT Game.6F3C297C
6F3C290C CMP DWORD PTR DS:[EAX+20],0 ; 该指针+20是否0
6F3C2910 JNZ SHORT Game.6F3C297C
6F3C2912 MOV ECX,DWORD PTR DS:[6FABBE4C] ; 检查通过
6F3C2918 PUSH ESI
6F3C2919 PUSH EDI
6F3C291A MOVZX EDI,WORD PTR DS:[ECX+28] ; edi = 玩家序号
6F3C291E PUSH EDI
6F3C291F CALL Game.6F3A1F50 ; GetPlayerSelection
6F3C2924 MOV ESI,DWORD PTR DS:[EAX+34]
6F3C2927 TEST ESI,ESI
6F3C2929 JE SHORT Game.6F3C297A
6F3C292B CMP DWORD PTR SS:[ESP+14],0 ; 参数:添加=true?
6F3C2930 JE SHORT Game.6F3C295A
6F3C2932 TEST BYTE PTR DS:[EBX+20],2 ; [单位+20] = 2?
6F3C2936 JE SHORT Game.6F3C2970
6F3C2938 PUSH 1
6F3C293A PUSH 1
6F3C293C PUSH 0
6F3C293E PUSH EDI
6F3C293F PUSH EBX
6F3C2940 MOV ECX,ESI
6F3C2942 CALL Game.6F4172F0 ; 添加单位到本地选择
6F3C2947 PUSH 0
6F3C2949 MOV ECX,ESI
6F3C294B CALL Game.6F417C00 ; 同步选择
6F3C2950 POP EDI
6F3C2951 POP ESI
6F3C2952 XOR ECX,ECX
6F3C2954 POP EBX
6F3C2955 JMP Game.6F3330C0 ; SetGameUI
6F3C295A PUSH 1 ; 添加=false
6F3C295C PUSH 1
6F3C295E PUSH EDI
6F3C295F PUSH EBX
6F3C2960 MOV ECX,ESI
6F3C2962 CALL Game.6F417450 ; 删除单位从本地选择
6F3C2967 PUSH 0
6F3C2969 MOV ECX,ESI
6F3C296B CALL Game.6F417C00 ; 同步选择
6F3C2970 POP EDI ; 如果[单位+20]=2跳过同步
6F3C2971 POP ESI
6F3C2972 XOR ECX,ECX
6F3C2974 POP EBX
6F3C2975 JMP Game.6F3330C0 ; SetGameUI
6F3C297A POP EDI
6F3C297B POP ESI
6F3C297C POP EBX
6F3C297D RETN |
|