|
发表于 2010-3-19 18:52:35
|
显示全部楼层
用C的话这样就可以了
CString GetHp()//获取当前血值
{
DWORD hpbase;
DWORD hpmaxbase;
CString hp;
_asm
{
mov eax,DWORD PTR DS:[CharacterBase]
mov eax,DWORD PTR DS:[eax+0x44c]
mov hpbase,eax
mov eax,DWORD PTR DS:[CharacterBase]
mov eax,DWORD PTR DS:[eax+0x454]
mov hpmaxbase,eax
}
hp.Format("%d/%d",hpbase,hpmaxbase);
return hp;
}
CString GetMp()//获取当前蓝值
{
DWORD mpbase;
DWORD mpmaxbase;
CString mp;
_asm
{
mov eax,DWORD PTR DS:[CharacterBase]
mov eax,DWORD PTR DS:[eax+0x450]
mov mpbase,eax
mov eax,DWORD PTR DS:[CharacterBase]
mov eax,DWORD PTR DS:[eax+0x458]
mov mpmaxbase,eax
}
mp.Format ("%d/%d",mpbase,mpmaxbase);
return mp;
} |
评分
-
查看全部评分
|