diff --git a/reapi/include/reunion_api.h b/reapi/include/reunion_api.h index 8ba5c36..c879758 100644 --- a/reapi/include/reunion_api.h +++ b/reapi/include/reunion_api.h @@ -34,6 +34,10 @@ enum reu_authkey_kind class IReunionApi { public: + // NOTE: GetMajorVersion, GetMinorVersion have been since version 0.1.0.92c + int version_major; + int version_minor; + enum { LONG_AUTHID_LEN = 16 diff --git a/reapi/src/mods/mod_reunion_api.cpp b/reapi/src/mods/mod_reunion_api.cpp index 68bed28..0001666 100644 --- a/reapi/src/mods/mod_reunion_api.cpp +++ b/reapi/src/mods/mod_reunion_api.cpp @@ -12,28 +12,28 @@ bool ReunionApi_Init() if (!g_ReunionApi) return false; - if (g_ReunionApi->GetMajorVersion() != REUNION_API_VERSION_MAJOR) + if (g_ReunionApi->version_major != REUNION_API_VERSION_MAJOR) { - UTIL_ServerPrint("[%s]: Reunion API major version mismatch; expected %d, real %d\n", Plugin_info.logtag, REUNION_API_VERSION_MAJOR, g_ReunionApi->GetMajorVersion()); + UTIL_ServerPrint("[%s]: Reunion API major version mismatch; expected %d, real %d\n", Plugin_info.logtag, REUNION_API_VERSION_MAJOR, g_ReunionApi->version_major); // need to notify that it is necessary to update the Reunion. - if (g_ReunionApi->GetMajorVersion() < REUNION_API_VERSION_MAJOR) + if (g_ReunionApi->version_major < REUNION_API_VERSION_MAJOR) { UTIL_ServerPrint("[%s]: Please update the Reunion up to a major version API >= %d\n", Plugin_info.logtag, REUNION_API_VERSION_MAJOR); } // need to notify that it is necessary to update the module. - else if (g_ReunionApi->GetMajorVersion() > REUNION_API_VERSION_MAJOR) + else if (g_ReunionApi->version_major > REUNION_API_VERSION_MAJOR) { - UTIL_ServerPrint("[%s]: Please update the %s up to a major version API >= %d\n", Plugin_info.logtag, Plugin_info.logtag, g_ReunionApi->GetMajorVersion()); + UTIL_ServerPrint("[%s]: Please update the %s up to a major version API >= %d\n", Plugin_info.logtag, Plugin_info.logtag, g_ReunionApi->version_major); } return false; } - if (g_ReunionApi->GetMinorVersion() < REUNION_API_VERSION_MINOR) + if (g_ReunionApi->version_minor < REUNION_API_VERSION_MINOR) { - UTIL_ServerPrint("[%s]: Reunion API minor version mismatch; expected at least %d, real %d\n", Plugin_info.logtag, REUNION_API_VERSION_MINOR, g_ReunionApi->GetMinorVersion()); + UTIL_ServerPrint("[%s]: Reunion API minor version mismatch; expected at least %d, real %d\n", Plugin_info.logtag, REUNION_API_VERSION_MINOR, g_ReunionApi->version_minor); UTIL_ServerPrint("[%s]: Please update the Reunion up to a minor version API >= %d\n", Plugin_info.logtag, REUNION_API_VERSION_MINOR); return false; }