prevent asynchronous destruction violation

spontaneous "C_BasePlayer::RemoveSplitScreenPlayer" seems to be cause. couldn't reproduce to investigate further
This commit is contained in:
explorer
2025-02-05 19:58:15 +03:00
parent 92271625c8
commit 386afb13c1

View File

@ -46,6 +46,8 @@ void __thiscall Redirected_Copy_Command(void* Unknown_Parameter, Command_Structu
void* Local_Player = *(void**)((unsigned __int32)Client_Module + 7498712); void* Local_Player = *(void**)((unsigned __int32)Client_Module + 7498712);
if (Local_Player != nullptr)
{
Global_Variables_Structure* Global_Variables = *(Global_Variables_Structure**)((unsigned __int32)Client_Module + 7096744); Global_Variables_Structure* Global_Variables = *(Global_Variables_Structure**)((unsigned __int32)Client_Module + 7096744);
if (Extra_Commands == -1) if (Extra_Commands == -1)
@ -922,6 +924,7 @@ void __thiscall Redirected_Copy_Command(void* Unknown_Parameter, Command_Structu
} }
Command->Buttons &= ~524288; Command->Buttons &= ~524288;
}
(decltype(&Redirected_Copy_Command)(Original_Copy_Command_Caller))(Unknown_Parameter, Command); (decltype(&Redirected_Copy_Command)(Original_Copy_Command_Caller))(Unknown_Parameter, Command);
} }