From 82ee1b0aac03f2045d1105a629e1e34df1587ab5 Mon Sep 17 00:00:00 2001 From: s1lent Date: Wed, 24 Jan 2018 17:34:06 +0700 Subject: [PATCH] ReHLDS API: Implemented CRehldsServerStatic::GetMaxClientsLimit Bump minor version --- gradle.properties | 2 +- rehlds/public/rehlds/rehlds_api.h | 2 +- rehlds/public/rehlds/rehlds_interfaces.h | 1 + rehlds/rehlds/rehlds_interfaces_impl.cpp | 5 +++++ rehlds/rehlds/rehlds_interfaces_impl.h | 1 + 5 files changed, 9 insertions(+), 2 deletions(-) diff --git a/gradle.properties b/gradle.properties index e05d574..8ea24ef 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,3 +1,3 @@ majorVersion=3 -minorVersion=3 +minorVersion=4 maintenanceVersion=0 diff --git a/rehlds/public/rehlds/rehlds_api.h b/rehlds/public/rehlds/rehlds_api.h index 938bd0c..a32af12 100644 --- a/rehlds/public/rehlds/rehlds_api.h +++ b/rehlds/public/rehlds/rehlds_api.h @@ -37,7 +37,7 @@ #include "pr_dlls.h" #define REHLDS_API_VERSION_MAJOR 3 -#define REHLDS_API_VERSION_MINOR 3 +#define REHLDS_API_VERSION_MINOR 4 //Steam_NotifyClientConnect hook typedef IHookChain IRehldsHook_Steam_NotifyClientConnect; diff --git a/rehlds/public/rehlds/rehlds_interfaces.h b/rehlds/public/rehlds/rehlds_interfaces.h index 7d6a086..d2db710 100644 --- a/rehlds/public/rehlds/rehlds_interfaces.h +++ b/rehlds/public/rehlds/rehlds_interfaces.h @@ -104,6 +104,7 @@ public: virtual IGameClient* GetClient(int id) = 0; virtual client_t* GetClient_t(int id) = 0; virtual int GetIndexOfClient_t(client_t* client) = 0; + virtual int GetMaxClientsLimit() = 0; }; class IRehldsServerData { diff --git a/rehlds/rehlds/rehlds_interfaces_impl.cpp b/rehlds/rehlds/rehlds_interfaces_impl.cpp index f4d3c0b..8d02a03 100644 --- a/rehlds/rehlds/rehlds_interfaces_impl.cpp +++ b/rehlds/rehlds/rehlds_interfaces_impl.cpp @@ -155,6 +155,11 @@ int EXT_FUNC CRehldsServerStatic::GetMaxClients() return g_psvs.maxclients; } +int EXT_FUNC CRehldsServerStatic::GetMaxClientsLimit() +{ + return g_psvs.maxclientslimit; +} + bool EXT_FUNC CRehldsServerStatic::IsLogActive() { return g_psvs.log.active ? true : false; diff --git a/rehlds/rehlds/rehlds_interfaces_impl.h b/rehlds/rehlds/rehlds_interfaces_impl.h index 8616dcd..9164a02 100644 --- a/rehlds/rehlds/rehlds_interfaces_impl.h +++ b/rehlds/rehlds/rehlds_interfaces_impl.h @@ -121,6 +121,7 @@ public: virtual IGameClient* GetClient(int id); virtual client_t* GetClient_t(int id); virtual int GetIndexOfClient_t(client_t* client); + virtual int GetMaxClientsLimit(); }; class CRehldsServerData : public IRehldsServerData {