2022-07-08 23:42:28 +02:00
|
|
|
#include "core/stdafx.h"
|
|
|
|
#include "server/vengineserver_impl.h"
|
|
|
|
#include "server/persistence.h"
|
|
|
|
|
|
|
|
#if defined (GAMEDLL_S0) || defined (GAMEDLL_S1)
|
|
|
|
bool Persistence_SetXP(int a1, int* a2)
|
|
|
|
{
|
2023-03-01 00:09:38 +01:00
|
|
|
g_pEngineServer->PersistenceAvailable(nullptr, a1);
|
2022-07-08 23:42:28 +02:00
|
|
|
return v_Persistence_SetXP(a1, a2);
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2023-01-25 02:26:52 +01:00
|
|
|
void VPersistence::Attach() const
|
2022-07-08 23:42:28 +02:00
|
|
|
{
|
|
|
|
#if defined (GAMEDLL_S0) || defined (GAMEDLL_S1)
|
|
|
|
DetourAttach((LPVOID*)&v_Persistence_SetXP, &Persistence_SetXP);
|
|
|
|
#endif
|
|
|
|
}
|
2023-01-25 02:26:52 +01:00
|
|
|
void VPersistence::Detach() const
|
2022-07-08 23:42:28 +02:00
|
|
|
{
|
|
|
|
#if defined (GAMEDLL_S0) || defined (GAMEDLL_S1)
|
|
|
|
DetourDetach((LPVOID*)&v_Persistence_SetXP, &Persistence_SetXP);
|
|
|
|
#endif
|
|
|
|
}
|