amxmodx/amxmodx/fakemeta.cpp

34 lines
806 B
C++
Raw Normal View History

2014-08-04 12:36:20 +04: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 14:54:09 +04:00
#include "amxmodx.h"
#include "fakemeta.h"
int LoadMetamodPlugin(const char *path, void **handle, PLUG_LOADTIME now)
{
2006-02-09 00:59:02 +03:00
int err = 0;
if ( (err = LOAD_PLUGIN(PLID, path, now, handle)) || !*handle)
{
2006-02-09 00:59:02 +03:00
LOG_MESSAGE(PLID, "Can't Attach Module \"%s\".", path);
return 0;
}
2006-02-09 00:59:02 +03:00
return 1;
}
2006-02-09 00:59:02 +03:00
int UnloadMetamodPlugin(void *handle)
{
2006-02-09 00:59:02 +03:00
if (UNLOAD_PLUGIN_BY_HANDLE(PLID, (void *)handle, PT_ANYTIME, PNL_PLUGIN))
{
2006-02-09 00:59:02 +03:00
return 0;
}
2006-02-09 00:59:02 +03:00
return 1;
}