冰楓論壇
標題:
TWMS_V113 快速恢復HP/MP 合併版
[打印本頁]
作者:
qkckcqkckcq
時間:
2012-9-26 12:21
標題:
TWMS_V113 快速恢復HP/MP 合併版
//==================================================
// TWMS_V113 快速恢復HP/MP 合併版
//
// 代碼原創:qqazedctgb
//
// 代碼:0042A553
//
// EIP:HookFR
//
// 說明:每次恢復10倍HP,8倍MP
//==================================================
[Enable]
alloc(HookFR,1024)
********symbol(HookFR)
label(HookRet)
label(HPHandler)
label(MPHandler)
label(FastRecoverHP)
label(DoNormalHP)
label(HPCheck)
alloc(HPCounter,4)
alloc(SetHPCounter,4)
alloc(RecoverTime,4)
********symbol(SetHPCounter)
label(FastRecoverMP)
label(DoNormalMP)
label(MPCheck)
alloc(MPCounter,4)
alloc(SetMPCounter,4)
********symbol(SetMPCounter)
HookFR:
cmp [esp],00A1F484
je HPHandler
cmp [esp],00A1F5F2
je MPHandler
HookRet:
push ebp
mov ebp,esp
sub esp,0c
jmp 0042A559
HPHandler:
mov [esp],FastRecoverHP
jmp HookRet
MPHandler:
mov [esp],FastRecoverMP
jmp HookRet
FastRecoverHP:
push eax
mov eax,[ebp-1c]
mov [RecoverTime],eax
pop eax
cmp [HPCounter],0
je HPCheck
dec [HPCounter]
cmp ebx,1
jmp 00A1F487
HPCheck:
sub [RecoverTime],0A
cmp ebx,[RecoverTime]
jna DoNormalHP
push eax
mov eax,[SetHPCounter]
dec eax
mov [HPCounter],eax
pop eax
DoNormalHP:
cmp ebx,[ebp-1c]
jmp 00A1F487
FastRecoverMP:
cmp [MPCounter],0
je MPCheck
dec [MPCounter]
cmp ebx,1
jmp 00A1F5F8
MPCheck:
cmp ebx,00002134
jna DoNormalMP
push eax
mov eax,[SetMPCounter]
dec eax
mov [MPCounter],eax
pop eax
DoNormalMP:
cmp ebx,00002134
jmp 00A1F5F8
SetHPCounter:
dd A // 10倍HP,易斷線的請調低倍數
SetMPCounter:
dd 8 // 8倍MP,易斷線的請調低倍數
[Disable]
un********symbol(HookFR)
dealloc(HookFR)
dealloc(HPCounter)
dealloc(SetHPCounter)
dealloc(RecoverTime)
un********symbol(SetHPCounter)
dealloc(MPCounter)
dealloc(SetMPCounter)
un********symbol(SetMPCounter)
歡迎光臨 冰楓論壇 (https://bingfong.com/)
Powered by 冰楓