-
Автор темы
- #1
//this shit code I pasted from the pastebin and made it under ikaros
in hooks.cpp
in CreateMove()
in hooks.cpp
Код:
bool __fastcall hkdWriteUsercmdDeltaToBuffer(void* ecx, void*, bf_write* buf, int from, int to, bool isnewcommand)
{
auto GetUserCmd = [](int sequence_number)
{
return &(*(CUserCmd**)((DWORD)Ikaros.m_pInput + 0xC4))[sequence_number % MULTIPLAYER_BACKUP];
};
static auto WriteUsercmd = (void(__cdecl*)(bf_write*, CUserCmd*, CUserCmd*))(Ikaros.m_pNeeded->FindPattern("client.dll", "51 8B 44 24 10 8B 48 04"));
CUserCmd nullcmd, *f, *t;
if (from == -1)
f = &nullcmd;
else
{
f = GetUserCmd(from);
if (!f)
f = &nullcmd;
}
t = GetUserCmd(to);
if (!t)
t = &nullcmd;
WriteUsercmd(buf, t, f);
return (!(*(BYTE*)((DWORD)buf + 0x10)));
}
Код:
auto netchannel = Ikaros.m_pEngine->GetNetChannelInfo();
static auto module_engine = (DWORD)GetModuleHandleA("engine.dll");
if (Ikaros.m_pCvars->LagExploit && module_engine)
{
bSendPacket = (sequence_number % 10) == 0;
cmd->command_number += 5 * MULTIPLAYER_BACKUP;
*(int*)((DWORD)module_engine + 0x39539C) += 5 * MULTIPLAYER_BACKUP; // lastoutgoingcommand
*(int*)((DWORD)netchannel + 0x8) += 5 * MULTIPLAYER_BACKUP; // m_nOutSequenceNr
}
Последнее редактирование: