From 15aca1d7997d1c145dbb60450efe564837872641 Mon Sep 17 00:00:00 2001 From: Nord1cWarr1or <47604048+Nord1cWarr1or@users.noreply.github.com> Date: Tue, 28 Dec 2021 18:32:53 +0300 Subject: [PATCH] Fix wrong native error description (#236) * Update natives_common.cpp * Update reapi_engine.inc * Update reapi_engine.inc add error description * Update natives_common.cpp * reapi_engine.inc: add error in `set_key_value` desc * natives_common.cpp: add error in `set_key_value` desc --- reapi/extra/amxmodx/scripting/include/reapi_engine.inc | 4 ++-- reapi/src/natives/natives_common.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/reapi/extra/amxmodx/scripting/include/reapi_engine.inc b/reapi/extra/amxmodx/scripting/include/reapi_engine.inc index 52c17a5d..e5a2ac8d 100644 --- a/reapi/extra/amxmodx/scripting/include/reapi_engine.inc +++ b/reapi/extra/amxmodx/scripting/include/reapi_engine.inc @@ -39,8 +39,7 @@ native any:get_ucmd(const ucmd, const UCmd:var, any:...); * @param maxlen Maximum size of the buffer * * @return Number of cells written to buffer -* @error If the index is not within the range of 1 to MaxClients or -* the client is not connected, an error will be thrown. +* @error If invalid buffer handler provided, an error will be thrown. */ native get_key_value(const pbuffer, const key[], const value[], const maxlen); @@ -52,6 +51,7 @@ native get_key_value(const pbuffer, const key[], const value[], const maxlen); * @param value Value to set * * @noreturn +* @error If invalid buffer handler provided, an error will be thrown. */ native set_key_value(const pbuffer, const key[], const value[]); diff --git a/reapi/src/natives/natives_common.cpp b/reapi/src/natives/natives_common.cpp index 18d8a8ee..6315653c 100644 --- a/reapi/src/natives/natives_common.cpp +++ b/reapi/src/natives/natives_common.cpp @@ -122,8 +122,7 @@ cell AMX_NATIVE_CALL amx_get_viewent(AMX *amx, cell *params) * @param maxlen Maximum size of the buffer * * @return Number of cells written to buffer -* @error If the index is not within the range of 1 to MaxClients or -* the client is not connected, an error will be thrown. +* @error If invalid buffer handler provided, an error will be thrown. * * native get_key_value(const pbuffer, const key[], const value[], const maxlen); */ @@ -152,6 +151,7 @@ cell AMX_NATIVE_CALL amx_get_key_value(AMX *amx, cell *params) * @param value Value to set * * @noreturn +* @error If invalid buffer handler provided, an error will be thrown. * * native set_key_value(const &pbuffer, const key[], const value[]); */