2014-08-04 03:36:20 -05:00
|
|
|
// vim: set ts=4 sw=4 tw=99 noet:
|
|
|
|
//
|
|
|
|
// AMX Mod X, based on AMX Mod by Aleksander Naszko ("OLO").
|
|
|
|
// Copyright (C) The AMX Mod X Development Team.
|
|
|
|
//
|
|
|
|
// This software is licensed under the GNU General Public License, version 3 or higher.
|
|
|
|
// Additional exceptions apply. For full license details, see LICENSE.txt or visit:
|
|
|
|
// https://alliedmods.net/amxmodx-license
|
2004-04-22 10:54:09 +00:00
|
|
|
|
|
|
|
#include "amxmodx.h"
|
|
|
|
#include "fakemeta.h"
|
|
|
|
|
2005-07-22 19:32:16 +00:00
|
|
|
int LoadMetamodPlugin(const char *path, void **handle, PLUG_LOADTIME now)
|
|
|
|
{
|
2006-02-08 21:59:02 +00:00
|
|
|
int err = 0;
|
|
|
|
if ( (err = LOAD_PLUGIN(PLID, path, now, handle)) || !*handle)
|
2005-07-22 19:32:16 +00:00
|
|
|
{
|
2006-02-08 21:59:02 +00:00
|
|
|
LOG_MESSAGE(PLID, "Can't Attach Module \"%s\".", path);
|
|
|
|
return 0;
|
2005-07-22 19:32:16 +00:00
|
|
|
}
|
2006-02-08 21:59:02 +00:00
|
|
|
|
|
|
|
return 1;
|
2005-07-22 19:32:16 +00:00
|
|
|
}
|
2006-02-08 21:59:02 +00:00
|
|
|
|
2005-07-22 19:32:16 +00:00
|
|
|
int UnloadMetamodPlugin(void *handle)
|
|
|
|
{
|
2006-02-08 21:59:02 +00:00
|
|
|
if (UNLOAD_PLUGIN_BY_HANDLE(PLID, (void *)handle, PT_ANYTIME, PNL_PLUGIN))
|
2005-07-22 19:32:16 +00:00
|
|
|
{
|
2006-02-08 21:59:02 +00:00
|
|
|
return 0;
|
2005-07-22 19:32:16 +00:00
|
|
|
}
|
|
|
|
|
2006-02-08 21:59:02 +00:00
|
|
|
return 1;
|
2005-07-22 19:32:16 +00:00
|
|
|
}
|