2006-09-08 14:49:54 +00:00
|
|
|
/**
|
|
|
|
* AMX Mod Compatibility engine
|
|
|
|
* by the AMX Mod X Development Team
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include <amxmodx>
|
|
|
|
#include <fun> //we want fun running for extra compatibility
|
|
|
|
#include <engine> //we want engine running for extra compatibility
|
|
|
|
#include <fakemeta>
|
|
|
|
#include <translator>
|
|
|
|
#define AMXMODX_NOAUTOLOAD
|
|
|
|
#include <cstrike>
|
|
|
|
#include <sqlx>
|
|
|
|
|
|
|
|
#define MOD_NORMAL 0
|
|
|
|
#define MOD_CSTRIKE 1
|
|
|
|
|
|
|
|
new g_ModType = MOD_NORMAL
|
|
|
|
new g_MaxPlayers
|
|
|
|
|
|
|
|
#include "core.sma"
|
|
|
|
#include "vexdum.sma"
|
|
|
|
#include "mysql.sma"
|
|
|
|
|
|
|
|
public plugin_init()
|
|
|
|
{
|
2006-09-12 07:59:56 +00:00
|
|
|
register_plugin("AMX Mod Compat Engine", "1.76.rc4", "AMXX Dev Team")
|
2006-09-08 14:49:54 +00:00
|
|
|
|
|
|
|
g_MaxPlayers = get_maxplayers()
|
|
|
|
|
|
|
|
VexdUM_Register()
|
|
|
|
}
|
|
|
|
|
|
|
|
public plugin_natives()
|
|
|
|
{
|
|
|
|
set_module_filter("Plugin_ModuleFilter")
|
2006-09-10 09:21:09 +00:00
|
|
|
set_native_filter("Plugin_NativeFilter")
|
2006-09-08 14:49:54 +00:00
|
|
|
|
|
|
|
new modname[32]
|
|
|
|
get_modname(modname, 31)
|
|
|
|
if (equali(modname, "cstrike") || equali(modname, "czero"))
|
|
|
|
{
|
|
|
|
g_ModType = MOD_CSTRIKE
|
|
|
|
}
|
|
|
|
|
|
|
|
Core_Natives()
|
|
|
|
VexdUM_Natives()
|
|
|
|
MySQL_Natives()
|
|
|
|
}
|
|
|
|
|
|
|
|
public Plugin_ModuleFilter(const module[])
|
|
|
|
{
|
2006-09-10 09:21:09 +00:00
|
|
|
if (equali(module, "sqlx") || equali(module, "cstrike"))
|
|
|
|
{
|
|
|
|
return PLUGIN_HANDLED
|
|
|
|
}
|
|
|
|
|
|
|
|
return PLUGIN_CONTINUE
|
|
|
|
}
|
|
|
|
|
|
|
|
public Plugin_NativeFilter(const name[], index, trap)
|
|
|
|
{
|
|
|
|
if (!trap)
|
2006-09-08 14:49:54 +00:00
|
|
|
{
|
|
|
|
return PLUGIN_HANDLED
|
|
|
|
}
|
|
|
|
|
|
|
|
return PLUGIN_CONTINUE
|
|
|
|
}
|
|
|
|
|
|
|
|
public client_connect(id)
|
|
|
|
{
|
|
|
|
VexdUM_ClientConnect(id)
|
|
|
|
}
|
|
|
|
|