mirror of
https://github.com/accelerator74/l4dtoolz.git
synced 2025-07-19 01:48:39 +08:00
2.0.1
Always reply to a lobby request if the server is already reserved.
This commit is contained in:
@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
const char* engine_dll = "engine.so";
|
const char* engine_dll = "engine.so";
|
||||||
int slots_offs = 94; // m_numGameSlots (in CGameServer::ExecGameTypeCfg)
|
int slots_offs = 94; // m_numGameSlots (in CGameServer::ExecGameTypeCfg)
|
||||||
|
int reserved_offs = 360; // IsReserved() (in CBaseServer::ReplyReservationRequest)
|
||||||
int reservation_idx = 60; // CBaseServer::ReplyReservationRequest(netadr_s&, bf_read&) vtable
|
int reservation_idx = 60; // CBaseServer::ReplyReservationRequest(netadr_s&, bf_read&) vtable
|
||||||
int maxhuman_idx = 132; // CTerrorGameRules::GetMaxHumanPlayers vtable
|
int maxhuman_idx = 132; // CTerrorGameRules::GetMaxHumanPlayers vtable
|
||||||
|
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
int sv_offs = 6; // IServer pointer (in IVEngineServer::CreateFakeClient)
|
int sv_offs = 6; // IServer pointer (in IVEngineServer::CreateFakeClient)
|
||||||
int slots_offs = 96; // m_numGameSlots (in CGameServer::ExecGameTypeCfg)
|
int slots_offs = 96; // m_numGameSlots (in CGameServer::ExecGameTypeCfg)
|
||||||
|
int reserved_offs = 46; // IsReserved() (in CBaseServer::ReplyReservationRequest)
|
||||||
int reservation_idx = 59; // CBaseServer::ReplyReservationRequest(netadr_s&, bf_read&) vtable
|
int reservation_idx = 59; // CBaseServer::ReplyReservationRequest(netadr_s&, bf_read&) vtable
|
||||||
int maxhuman_idx = 131; // CTerrorGameRules::GetMaxHumanPlayers vtable
|
int maxhuman_idx = 131; // CTerrorGameRules::GetMaxHumanPlayers vtable
|
||||||
|
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
const char* engine_dll = "engine_srv.so";
|
const char* engine_dll = "engine_srv.so";
|
||||||
int slots_offs = 95; // m_numGameSlots (in CGameServer::ExecGameTypeCfg)
|
int slots_offs = 95; // m_numGameSlots (in CGameServer::ExecGameTypeCfg)
|
||||||
|
int reserved_offs = 364; // IsReserved() (in CBaseServer::ReplyReservationRequest)
|
||||||
int reservation_idx = 62; // CBaseServer::ReplyReservationRequest(netadr_s&, bf_read&) vtable
|
int reservation_idx = 62; // CBaseServer::ReplyReservationRequest(netadr_s&, bf_read&) vtable
|
||||||
int maxhuman_idx = 137; // CTerrorGameRules::GetMaxHumanPlayers vtable
|
int maxhuman_idx = 137; // CTerrorGameRules::GetMaxHumanPlayers vtable
|
||||||
|
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
int sv_offs = 8; // IServer pointer (in IVEngineServer::CreateFakeClient)
|
int sv_offs = 8; // IServer pointer (in IVEngineServer::CreateFakeClient)
|
||||||
int slots_offs = 96; // m_numGameSlots (in CGameServer::ExecGameTypeCfg)
|
int slots_offs = 96; // m_numGameSlots (in CGameServer::ExecGameTypeCfg)
|
||||||
|
int reserved_offs = 46; // IsReserved() (in CBaseServer::ReplyReservationRequest)
|
||||||
int reservation_idx = 61; // CBaseServer::ReplyReservationRequest(netadr_s&, bf_read&) vtable
|
int reservation_idx = 61; // CBaseServer::ReplyReservationRequest(netadr_s&, bf_read&) vtable
|
||||||
int maxhuman_idx = 136; // CTerrorGameRules::GetMaxHumanPlayers vtable
|
int maxhuman_idx = 136; // CTerrorGameRules::GetMaxHumanPlayers vtable
|
||||||
|
|
||||||
|
@ -74,6 +74,10 @@ void Hook_ApplyGameSettings(KeyValues *pKV)
|
|||||||
void Hook_ReplyReservationRequest(netadr_s& adr, CBitRead& inmsg)
|
void Hook_ReplyReservationRequest(netadr_s& adr, CBitRead& inmsg)
|
||||||
{
|
{
|
||||||
if (sv_force_unreserved.GetInt()) {
|
if (sv_force_unreserved.GetInt()) {
|
||||||
|
if (g_pGameIServer != NULL) {
|
||||||
|
if (*(uint64_t*)(((uint**)g_pGameIServer)+reserved_offs) != 0)
|
||||||
|
RETURN_META(MRES_IGNORED);
|
||||||
|
}
|
||||||
RETURN_META(MRES_SUPERCEDE);
|
RETURN_META(MRES_SUPERCEDE);
|
||||||
}
|
}
|
||||||
RETURN_META(MRES_IGNORED);
|
RETURN_META(MRES_IGNORED);
|
||||||
@ -235,7 +239,7 @@ const char *l4dtoolz::GetLicense()
|
|||||||
|
|
||||||
const char *l4dtoolz::GetVersion()
|
const char *l4dtoolz::GetVersion()
|
||||||
{
|
{
|
||||||
return "2.0.0";
|
return "2.0.1";
|
||||||
}
|
}
|
||||||
|
|
||||||
const char *l4dtoolz::GetDate()
|
const char *l4dtoolz::GetDate()
|
||||||
|
Reference in New Issue
Block a user