111
This commit is contained in:
@@ -25,7 +25,7 @@ void hook::H_Register_Pack(void* Ecx)
|
||||
|
||||
void _fastcall hook::H_Register_DrawCode(DWORD thisc, int Seat, int a3, int a4, int a5, int a6)
|
||||
{
|
||||
|
||||
//请勿删除
|
||||
if (a3 == 9999 && a4 == 9999)
|
||||
{
|
||||
for (DrawCodestruct iter : DrawCodeT1_STL)
|
||||
@@ -35,6 +35,7 @@ void _fastcall hook::H_Register_DrawCode(DWORD thisc, int Seat, int a3, int a4,
|
||||
}
|
||||
DrawCodeT1_STL.clear();
|
||||
}
|
||||
//特殊
|
||||
if (a3 == 9999 && a4 == 9998)
|
||||
{
|
||||
|
||||
@@ -54,16 +55,28 @@ void _fastcall hook::H_Register_DrawCode(DWORD thisc, int Seat, int a3, int a4,
|
||||
}
|
||||
DrawCodeT2_STL.clear();
|
||||
}
|
||||
|
||||
//选角色
|
||||
if (a3 == 9999 && a4 == 9489)
|
||||
{
|
||||
uint32_t v = GetSqVm();
|
||||
SQPushRootTable(v);
|
||||
SQPushString(v, L"InitLenheartClass", -1);
|
||||
SQ_Get(v, -2);
|
||||
SQPushRootTable(v);
|
||||
SQPushString(v, L"Lenheart", -1);
|
||||
SQ_Call(v, 2, 1, 0);
|
||||
SQPop(v, 2);
|
||||
}
|
||||
|
||||
return DrawCodeF(thisc, Seat, a3, a4, a5, a6);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
int hook::RegisterHook()
|
||||
{
|
||||
|
||||
|
||||
|
||||
MH_Initialize();
|
||||
//Hook收包
|
||||
MH_CreateHook((void*)INIT_PACK_ADDRESS, &H_Register_Pack, reinterpret_cast<void**>(&Lpfn_Init));
|
||||
@@ -73,10 +86,10 @@ int hook::RegisterHook()
|
||||
MH_CreateHook((void*)INIT_NUT_DRAWCODE, &H_Register_DrawCode, reinterpret_cast<void**>(&DrawCodeF));
|
||||
|
||||
|
||||
|
||||
MH_EnableHook((void*)INIT_PACK_ADDRESS);
|
||||
MH_EnableHook((void*)INIT_NUT_ADDRESS);
|
||||
MH_EnableHook((void*)INIT_NUT_DRAWCODE);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user