I've been using a suicide hook from the OnOeS bot released by Hex for a plugin (Suicide5MinWait), it works just fine with beta 4 but with beta 5 it crashes (even if I change the hook to just print something to the console):
Hook *Suicide = new Hook;
void __cdecl Suicide_Hook(int PlayerID)
{
Console_Output("test\n");
}
void __declspec(naked) Suicide_Glue()
{
__asm
{
mov eax, [edi+6B4h];
push eax;
call Suicide_Hook;
add esp, 4;
pop edi;
pop ecx;
retn;
}
}
Suicide5MinWait::Suicide5MinWait()
{
RegisterEvent(EVENT_LOAD_LEVEL_HOOK,this);
RegisterEvent(EVENT_PLAYER_LEAVE_HOOK,this);
Suicide->Install('\xE9', 0x004BA144, (int)&Suicide_Glue, "");
}