diff --git a/plugins/include/amxconst.inc b/plugins/include/amxconst.inc index 3c0dbd6e..4672604f 100755 --- a/plugins/include/amxconst.inc +++ b/plugins/include/amxconst.inc @@ -322,3 +322,8 @@ enum { #define SND_CHANGE_VOL (1<<6) // change sound vol #define SND_CHANGE_PITCH (1<<7) // change sound pitch +enum LibType +{ + LibType_Library, + LibType_Class +}; diff --git a/plugins/include/amxmodx.inc b/plugins/include/amxmodx.inc index 74c70372..6a150a4e 100755 --- a/plugins/include/amxmodx.inc +++ b/plugins/include/amxmodx.inc @@ -911,9 +911,9 @@ native set_native_filter(const handler[]); * * Your handler will be called with this prototype: * - * public module_filter(const library[], bool:isClass); + * public module_filter(const library[], LibType:type); * library - library or class name of the module that is required - * isClass - true if the name is a library class, false if it's a normal module + * libtype - The type of requirement being checked (library/module or class). * * * set_module_filter() returns 0 on success (unlike most natives). @@ -939,6 +939,11 @@ native abort(error, const fmt[]="", {Float,_}:...); */ native module_exists(const logtag[]); +/** + * Checks if a library/class is loaded. This is the newer version of module_exists. + */ +native LibraryExists(const library[], LibType:type); + /** * Returns the next valid hudchannel for a user, from 1-4. */